Professional Documents
Culture Documents
Focus in Short
Focus in Short
VERBS
PRINT
LIST
SUM/WRITE
COUNT
Request:
Output:
+--------------------------------------------------------+
|
COMPANY_ID REGION_NO
|
|
---------- --------|
|
11701
01
|
Request:
Output:
+--------------------------------------------------------+
|
LIST COMPANY_ID ACCOUNT_NO
|
|
---- ---------- ---------|
|
1 11701
10001
|
|
2 11701
10200
|
Request:
Output:
+-------------------------------------------------------+
|
COMPANY_ID ACCOUNT_NO
AMOUNT
|
|
---------- --------------|
|
11701
10001
5,000.00
|
|
10200
404.00
|
|
20030
3,000.00
|
|
34600
200.00
|
|
70210
1,000.00 CR
|
High-to-Low
+-------------------------------+
|
BY (HIGHEST) {n} sortfield |
+-------------------------------+
Request:
TERMINATING FOCUS
END
Terminates a FOCUS request.
Function is processed.
User is returned to FOCUS command level.
RUN
QUIT
OFFLINE
Request:
Output:
+---------------------+
| PAGE 1
|
| LAST_NAME FIRST_NAME|
| --------- ----------|
| STEVENS
ALRED
|
|
.
.
|
|
.
.
|
|
.
.
|
+---------------------+
Then:
> OFFLINE
> RETYPE
> ONLINE
(Press ENTER)
(Press ENTER)
(Press ENTER)
Ouput:
+----------------------------+
|
DEPARTMENT
CURR_SAL
|
|
----------------|
|
MIS
$13,200.00 |
|
$18,480.00 |
|
$18,480.00 |
COUNT
If there is a BY phrase, the count represents the number of times a field is encountered
within that sortfield.
If there are no BY phrases, the count represents the number of times the field is
encountered within the entire file.
The word COUNT is placed in the column heading beneath the fieldname.
COUNT object1(...object95)
Request:
Output:
+-----------------------------+
|
|
| DEPARTMENT
CURR_SAL
|
| ----------------|
| MIS
$13,200.00 |
|
$18,480.00 |
|
$18,480.00 |
|
$21,780.00 |
COUNT *
Request:
+-------------------------+
|
CURR_SAL |
| DEPARTMENT
COUNT
|
| ----------------- |
| MIS
6 |
| PRODUCTION
6 |
|
|
|
|
Output:
+--------------+
| COUNT *
|
|
COUNT
|
| ------|
|
19
|
+--------------+
SORT
+---------------------------------------------------------+
|
BY (HIGHEST) sortfield (IN-GROUPS-OF quantity)
|
+---------------------------------------------------------+
Sortfield must be numeric
IN-GROUPS-OF must be used with the BY phrase.
If BY sortfield, then 1 line for each field value.
If BY sortfield IN-GROUPS-OF n, then 1 line for each category.
Values
Appear as
Category
------------0 - 9-------------------------------0
10 - 19------------------------------10
20 - 29------------------------------20
Request:
Output:
+------------------------+
|
CURR_SAL
ED_HRS |
|
------------- |
| $9,000.00
25.00 |
| $9,500.00
10.00 |
| $11,000.00
25.00 |
| $13,200.00
36.00 |
Request:
+---------------------------+
|
CURR_SAL
ED_HRS
|
|
------------|
|
$5,000.00
35.00
|
| $10,000.00
61.00
|
| $15,000.00
100.00
|
| $20,000.00
80.00
|
Output:
+---------------------------------------+
|
RANK
CURR_SAL
ED_HRS |
|
---------------- |
|
1
$29,700.00
.00 |
|
2
$27,062.00
45.00 |
|
3
$26,862.00
30.00 |
FOCUS QUERY REQUEST
(1) TABLE FILE filename
(2) {PRINT
} object1 ({AND } object2...object95 )
{LIST
}
{SUM/WRITE}
{COUNT
}
(3) (BY (HIGHEST) {n} sortfield (IN-GROUPS-OF qty))
n = # of instances
can be 1 to 32 sortfields
(4) RANKED BY (TOP
) {n}
(HIGHEST)
(LOWEST )
(5) {END }
{RUN }
{QUIT}
ACROSS
+----------------------------------------------------------------+
|
ACROSS (HIGHEST) sortfield (IN-GROUPS_OF quantity)
|
+----------------------------------------------------------------+
Output:
+--------------------------+
|
|
| DEPARTMENT
CURR_SAL
|
| ----------------|
| MIS
$108,002.00|
| PRODUCTION
$114,282.00|
+--------------------------+
+---------------------------+
| DEPARTMENT
|
|
MIS
PRODUCTION |
| --------------------------|
| $108,002.00
$114,282.00 |
|
|
+---------------------------+
IF
Request:
Output:
+-----------------------------------------------+
|
EMP_ID
|
|
DEPARTMENT
PAY_DATE
COUNT
|
|
---------------------|
|
MIS
82/05/28
4
|
|
82/06/30
4
|
|
82/07/30
4
|
|
82/08/31
5
|
+-----------------------------------------------+
LIMITING RECORDS
+----------------------------+
| IF RECORDLIMIT EQ n
|
+----------------------------+
Request:
IF RECORDLIMIT EQ 3
END
Output:
+--------------------------------------------------------------------+
|
LAST_NAME
FIRST_NAME
DEPARTMENT
|
|
--------------------------|
|
SMITH
MARY
MIS
|
|
JONES
DIANE
MIS
|
|
MCCOY
JOHN
MIS
|
+--------------------------------------------------------------------+
Only the first "n" records that meet all other screening conditions will be in the report
MASK
+---------------------------+
|
IF fieldname EQ 'mask' |
+---------------------------+
"$" is used to mask out positions whose values are irrelevant.
"$*" may be used to mark as irrelevant the remainder of the field value.
Request:
TABLE FILE EMPLOYEE
PRINT LN1
BY LAST_NAME BY FIRST_NAME BY TYPE
IF TYPE EQ 'H$*'
END
Output:
+----------------------------------------------------------------------+
| LAST_NAME
FIRST_NAME
TYPE ADDRESS_LN1
|
| --------------------- ----------|
| BANNING
JOHN
HSM
160 LOMBARDO AVE.
|
|
|
| BLACKWOOD
ROSEMARIE
HM
|
|
.
.
.
.
|
|
.
.
.
.
|
+-------------------------------------+
|
IF fieldname {CONTAINS} value
|
|
{OMITS}
|
+-------------------------------------+
The relations, CONTAINS and OMITS, are used only with alphanumeric fields.
If the value contains spaces, it must be in single quotes.
The field is searched for the value position by position.
For CONTAINS, if the value is found, the record is selected.
For OMITS, if the value is found, the record is not selected.
Request:
Output:
+--------------------------------------------------------------+
| BANK_NAME
LAST_NAME
FIRST_NAME
DAT_INC
|
| -------------------------------|
| BANK ASSOCIATION
CROSS
BARBARA
82/04/09 |
|
81/11/02 |
| ASSOCIATED
BLACKWOOD
ROSEMARIE
82/04/01 |
|
IRVING
JOAN
82/05/14 |
|
82/01/04 |
|
MCKNIGHT
ROGER
82/05/14 |
|
82/02/02 |
+--------------------------------------------------------------+
CONTAINS will include the selected values.
OMITS will not include the selected values.
REPORT FORMATTING
+------------------------------+
|
SET parameter= option
|
+------------------------------+
OR
+--------------------------------------+
|
ON TABLE SET parameter value
|
+--------------------------------------+
Allows you to change parameters of your FOCUS environment such as controlling output.
Can have as many parameters on a line as you can fit. Parameters are separated by a comma.
? SET
To inquire about the current settings--lists them on the screen.
Page 12-5 in Focus Manual.
Request:
SET NODATA=NONE
TABLE FILE FOCUSEXP
PRINT AMT AND ACCTNO
ACROSS ACCTT
BY REGNO BY COID
IF ACCTT EQ '1' OR '3'
IF READLIMIT EQ 15
END
Output:
+----------------------------------------------------------------------+
| PAGE
1
|
|
ACCOUNT_TYPE
|
|
1
3
|
| REGION_NO COMPANY_ID
AMOUNT ACCOUNT_NO
AMOUNT ACCOUNT_NO|
| ------------------------------------------------------------------ |
| 01
11701
5,000.00
10001
NONE NONE
|
|
404.00
10200
NONE NONE
|
|
NONE NONE
200.00
34600
|
| 02
31702
100.00
10001
NONE NONE
|
|
405.00
10003
NONE NONE
|
|
6,000.00
10200
NONE NONE
|
|
NONE NONE
50.00 CR 34600
|
| 03
34608
200.00
10001
NONE NONE
|
|
2,500.00
10003
NONE NONE
|
|
300.00
10200
NONE NONE
|
+----------------------------------------------------------------------+
RECORD RETRIEVAL
TABLEF provides for fastest retrieval of records from a given file.
RULES FOR USE :
1.
2.
3.
4.
5.
EXAMPLE:
EX CONMALLC
TABLEF FILE CONAMES
PRINT COID REGION SHORTNM CITYST BEDS
IF FACTYP EQ 'H'
IF STATUS EQ 2
END
FOCUS QUERY REQUEST
(1)
(2)
{PRINT
}
{LIST
}
{SUM/WRITE}
{COUNT
}
(3)
(4)
(5)
RANKED BY (TOP
) {n}
(HIGHEST)
(LOWEST )
(6)
(7)
{END }
{RUN }
{QUIT}
object1 ({AND
} object2...object95 )
Output:
+------------------------------------------------------------+
| PAY_DATE
GROSS
DED_AMT
DG_RATIO |
| ------------------------- |
|
|
| 82/08/31
$18,523.84
$9,486.90
.51 |
| 82/07/30
$14,508.84
$7,600.96
.52 |
| 82/06/30
$14,508.84
$7,600.96
.52 |
|
|
82/05/28
82/04/30
$13,698.35
$10,850.68
$7,438.28
$5,448.47
.54
.50
|
|
COMPUTE
Request:
Output:
+------------------------------------------------------------+
|
EMP_ID
ED_HRS
STATUS
|
|
---------------|
|
|
|
071382660
25.00
LOW
|
|
112847612
36.00
REQ. MET
|
|
117593129
50.00
REQ. MET
|
|
119265415
10.00
LOW
|
|
119329144
.00
LOW
|
|
123764317
30.00
REQ. MET
|
|
126724188
5.00
LOW
|
|
219984371
.00
LOW
|
|
326179357
75.00
REQ. MET
|
|
451123478
50.00
REQ. MET
|
|
543729165
25.00
LOW
|
|
818692173
45.00
REQ. MET
|
+------------------------------------------------------------+
DIRECT OPERATIONS
Prefix
-----MAX.
MIN.
AVE.
ASQ.
PCT.
FST.
LST.
TOT.
CNT.
SUM.
RPCT.
ALL.
ST.
CT.
MEANING
------Maximum Field Value
Minimum Field Value
Average Field Value
Average Sum of Squares Field Value
Percent of Column Total
First Retrieved Field Value
Last Retrieved Field Value
Column Total of Field Value
Count of Fields Retrieved
Sum of Fields Retrieved
Percent of Row Total
All Values (with missing descendents)
Subtotal value of field at a sort
break
Running column total of field
USAGE
----MAX.AMT
MIN.AMT
AVE.AMT
ASQ.AMT
PCT.AMT
FST.ACCTNO
LST.COID
TOT.AMT
CNT.ACCTNO
SUM.AMT
RPCT.AMT
ALL.ACCTNO
ST.SALES
CT.CURR_SAL
PREFIX ABBREVIATIONS
Request:
Output:
+--------------------------------------------------------------------+
|
NUMBER OF RECORDS IN TABLE = 24 LINES = 3
|
|
PAGE 1
|
|
PCT.
TOT.
|
|
REGION_NO
AMOUNT
AMOUNT
AMOUNT
|
|
-----------------------|
|
01
3,404.00
48.60
7.004.00
|
|
02
4,030.00
57.53
7,004.00
|
|
03
430.00 CR
6.13 CR
7,004.00
|
+--------------------------------------------------------------------+
REPORT FORMATTING
REPORT HEADING
PAGE HEADING
COLUMN POSITIONING
COLUMN TITLES
PAGE FOOTING
REPORT FOOTING
Request:
+------------------------------------+
|
TABLE FILE filename
|
|
HEADING(CENTER)
|
|
"
text
"
|
+------------------------------------+
TABLE FILE FOCUSEXP
HEADING
"<10 SAMPLE OUTPUT REPORT <113 PAGE: <TABPAGENO"
"<113 Printed &DATE"
"<113 TIME: &TOD"
"<18 <COID"
"</2"
PRINT AMT ACCTT COSTCTR
BY COID NOPRINT PAGE-BREAK
BY ACCTNO
END
Output:
+---------------------------------------------------------------------+
|
SAMPLE OUTPUT REPORT
PAGE:
1
|
|
PRINTED 8/01/88 |
|
TIME: 08.38.17 |
|
11701
|
|
|
|
|
|
ACCOUNT_NO
AMOUNT ACCOUNT_TYPE COST_CENTER
|
|
--------------- ------------ ----------|
|
10001
5,000.00
1
22
|
|
10200
404.00
1
20
|
|
20030
3,000.00
2
19
|
|
34600
200.00
3
19
|
|
70210
1,000.00 CR 4
32
|
|
80301
4,200.00 CR 4
29
|
+---------------------------------------------------------------------+
+--------------------------+
| TABLE FILE filename
|
| FOOTING(BOTTOM)(CENTER) |
| "
text
"
|
+--------------------------+
TABLE FILE FOCUSEXP
HEADING
"<10 SAMPLE OUTPUT REPORT <113 PAGE:<TABPAGENO"
"<113 Printed &DATE"
"<113 TIME: &TOD"
"<18 <COID"
"</2"
PRINT AMT ACCTT COSTCTR
+------+
| IN n|
+------+
Request:
TABLE FILE EMPLOYEE
PRINT BANK_ACCT
BY BANK_NAME
BY LAST_NAME
END
Output:
+-------------------------------+
+--------------------------------+
| BANK_NAME
LAST_NAME BAN|_AC|T
BANK_ACCT
BANK_NAME|
| ----------------- ---|---|-----------------|
LAST_NAME
---------
|
|
|
GREENSPAN
MCCOY
ROMANS
|
|
|
|
|
|
|
|
|
Output:
+-----------------------------+
|
TOTAL
|
|
CURRENT
EDUCATION
|
|
JOBCODE
HOURS
|
|
--------------|
Placing a comma in new column heading forces a new line.
Allows up to 5 lines of heading per column
COLUMN NOTATION
Request:
Output:
+---------------------------------------------------------------------+
|
PAGE
1
|
|
REGION_NO
AMOUNT ACCOUNT_TYPE
AMOUNT
COPCT|
|
-------------- ---------------------|
|
01
3,404.00
1
5,404.00
158.75|
|
2
3,000.00
88.13|
|
3
200.00
5.88|
|
4
5,200.00 CR -152.76|
|
02
4,030.00
1
6,505.00
161.41|
|
2
1,025.00
25.43|
|
3
50.00 CR
-1.24|
|
4
3,450.00 CR
-85.61|
|
03
430.00 CR 1
3,673.00
-854.19|
|
2
718.00
-166.98|
|
3
1,530.00 CR
355.81|
|
4
3,291.00 CR
765.35|
+---------------------------------------------------------------------+
Request:
GREENSPAN
MCCOY
ROMANS
|
|
|
|
|
|
|
|
|
|
--------01
Request:
---------11701
ACCOUNT_NO
AMOUNT
COST_CENTER
ACCOUNT_NO
AMOUNT
COST_CENTER
ACCOUNT_NO
AMOUNT
COST_CENTER
10001
5,000.00
22
10200
404.00
20
20030
3,000.00
19
|
|
|
|
|
|
|
|
|
|
Output:
+---------------------------------------------------------------------+
| PAGE
1
|
|
|
|
|
|
|
|
|
|
MPG
|
|
0
10
20
TOTAL
|
| CAR
|
| ---------------------------------------------|
|
|
| ALFA ROMEO
0
0
3
3
|
| AUDI
0
0
1
1
|
| BMW
0
4
2
6
|
| DATSUN
1
0
0
1
|
| JAGUAR
1
1
0
2
|
| TOTAL
3
6
9
18
|
+-----------------------------------------------------------------+----------------------------+
|
ON fieldname operation |
+----------------------------+
For Instance:
Request:
ON COID SKIP-LINE
|
4
2,300.00 CR
1
|
| *TOTAL COMPANY_ID 34608
425.00 CR
6
|
|
34902
1
673.00
3
|
|
2
268.00
1
|
|
3
45.00
1
|
|
4
991.00 CR
1
|
| *TOTAL COMPANY_ID 34902
5.00 CR
6
|
| *TOTAL REGION_NO 03
430.00 CR
12
|
| TOTAL
2,974.00
18
|
+---------------------------------------------------------------------+
Request:
Request:
Output:
+---------------------------------------------------------------------+
| REGION_NO COMPANY_ID ACCOUNT_TYPE
AMOUNT COUNT
|
| --------- ---------- ----------------- ---------|
| 01
11701
1
5,404.00
2
|
|
2
3,000.00
1
|
|
3
200.00
1
|
|
4
5,200.00 CR
2
|
| *TOTAL COMPANY_ID 11701
3,404.00
6
|
| *TOTAL REGION_NO 01
3,404.00
6
|
| 03
34608
1
3,000.00
3
|
|
2
450.00
1
|
|
3
1,575.00 CR
1
|
|
4
2,300.00 CR
1
|
| *TOTAL COMPANY_ID 34608
425.00 CR
6
|
AMTPER
-----2,702.00
3,000.00
200.00
-2,600.00
567.33
567.33
1,000.00
450.00
-1,575.00
-2,300.00
-70.83
|
34902
1
673.00
3
|
|
2
268.00
1
|
|
3
45.00
1
|
|
4
991.00 CR
1
|
| *TOTAL COMPANY_ID 34902
5.00 CR
6
|
| *TOTAL REGION_NO 03
430.00 CR
12
|
| TOTAL
2,974.00
18
|
+---------------------------------------------------------------------+
Request:
224.33
268.00
45.00
-991.00
-.83
-35.83
165.22
Output:
+---------------------------------------------------------------------+
|
ACCOUNT_NO
|
| REGION_NO COMPANY_ID ACCOUNT_TYPE
AMOUNT COUNT
|
| --------- ---------- ----------------- ---------|
| 01
11701
1
5,404.00
2
|
|
2
3,000.00
1
|
|
3
200.00
1
|
|
4
5,200.00 CR
2
|
| *TOTAL COMPANY_ID 11701
3,404.00
6
|
| 03
34608
1
3,000.00
3
|
|
2
450.00
1
|
|
3
1,575.00 CR
1
|
|
4
2,300.00 CR
1
|
| *TOTAL COMPANY_ID 34608
425.00 CR
6
|
|
34902
1
673.00
3
|
|
2
268.00
1
|
|
3
45.00
1
|
|
4
991.00 CR
1
|
| *TOTAL COMPANY_ID 34902
5.00 CR
6
|
| TOTAL
2,974.00
18
|
+---------------------------------------------------------------------+
Request:
TABLE FILE FOCUSEXP
PRINT ACCTNO AND AMT
BY REGNO BY COID
ON REGNO PAGE-BREAK
END
Output:
+-----------------------------------------------------------+
|
REGION_NO COMPANY_ID ACCOUNT_NO
AMOUNT
|
|
--------- ---------- --------------|
|
01
11701
10001
5,000.00
|
|
10200
404.00
|
|
20030
3,000.00
|
|
34600
200.00
|
|
70210
1,000.00 CR
|
|
80301
4,200.00 CR
|
|
PAGE
2
|
|
REGION_NO COMPANY_ID ACCOUNT_NO
AMOUNT
|
|
--------- ---------- --------------|
|
03
34608
10001
200.00
|
|
10003
2,500.00
|
|
10200
300.00
|
|
20030
450.00
|
|
34600
1,575.00 CR
|
|
80301
2,300.00 CR
|
AMTPER
-----2,702.00
3,000.00
200.00
2,600.00
567.33
1,000.00
450.00
1,575.00
2,300.00
-70.83
224.33
268.00
45.00
-991.00
-.83
165.22
|
34902
10001
260.00
|
|
10003
428.00
|
|
10200
15.00 CR
|
|
20030
268.00
|
|
34600
45.00
|
|
80301
991.00 CR
|
+-----------------------------------------------------------+
Request:
Output:
+---------------------------------------------------------+
|
REGION_NO COMPANY_ID ACCOUNT_NO
AMOUNT
|
|
--------- ---------- --------------|
|
01
11701
10001
5,000.00
|
|
10200
404.00
|
|
20030
3,000.00
|
|
34600
200.00
|
|
70210
1,000.00 CR
|
|
80301
4,200.00 CR
|
|
|
|
03
34608
10001
200.00
|
|
10003
2,500.00
|
|
10200
300.00
|
|
20030
450.00
|
|
34600
1,575.00 CR
|
|
80301
2,300.00 CR
|
|
34902
10001
260.00
|
|
10003
428.00
|
|
10200
15.00 CR
|
|
20030
268.00
|
|
34600
45.00
|
|
80301
991.00 CR
|
+---------------------------------------------------------+
FOCEXEC
FOCEXEC is a FOCUS executable procedure.
FOCUS program is stored as a member in the 'TEST.FOCUS.EXEC' dataset.
Can include the TSO ALLOC statement in the FOCEXEC.
-* indicates that the line is a comment.
-TYPE MESSAGE sends the message to the screen.
To execute the FOCEXEC:
Go into FOCUS.
Type EX MEMBERNAME. Example:
EX TRxx01.
Request:
-* This program ....
TABLE FILE CAR
COUNT MODEL
ACROSS MPG IN-GROUPS-OF 10
BY CAR ROW-TOTAL COLUMN-TOTAL
END
-TYPE PROCESSING ENDS
Output:
+---------------------------------------------------------------------+
| PAGE
1
|
|
|
|
MPG
|
|
0
10
20
TOTAL
|
| CAR
|
| ---------------------------------------------|
|
|
| ALFA ROMEO
0
0
3
3
|
| AUDI
0
0
1
1
|
| BMW
0
4
2
6
|
| DATSUN
1
0
0
1
|
| JAGUAR
1
1
0
2
|
| JENSEN
0
1
0
1
|
| MASERATI
1
0
0
1
|
| PEUGEOT
0
0
1
1
|
| TOYOTA
0
0
1
1
|
| TRIUMPH
0
0
1
1
|
|
|
| TOTAL
3
6
9
18
|
+---------------------------------------------------------------------+
EXTRACTING FILES
Request:
TABLE FILE EMPLOYEE
SUM CURR_SAL
ACROSS DEPARTMENT
BY CURR_JOBCODE
END
Output:
+-----------------------------------++--------------------------------+
|
DEPARTMENT
||
|
| CURR_JOBCODE
MIS
PRODUCTION
|| ? hold
|
| __________________________________||
|
| A01
.
$9,500.00|| DEFINITION OF CURRENT HOLD FILE|
| A07
$9,000.00
$11,000.00||
|
| A15
.
$26,862.00|| FIELDNAME
ALIAS
FORMAT |
| A17
$27,062.00
$29,700.00||
|
| B02
$18,480.00
$16,100.00|| CURR_JOBCODE
E01
A3
|
| B03
$18,480.00
.|| CURR_SAL
E02
D12.2M |
| B04
$21,780.00
$21,120.00|| CURR_SAL
E03
D12.2M |
| B14
$13,200.00
.||
|
+-----------------------------------++--------------------------------+
DEFINE FILE
Creates new fields based on existing database field values.
Changes field length to accommodate sums and totals.
Changes field format so FOCUS special functions can be used.
Creates new fields using FOCUS special functions.
Defined fields are temporary.
Exist only for this FOCUS session.
Defined fields may also be put into the file's Master File
Description if the expression uses fields from that segment only.
+----------------------------------------+
| DEFINE FILE filename
|
|
fieldname (/format)=expression;
|
| .
|
| .
|
| .
|
| END
|
+----------------------------------------+
where:
fieldname
format
expression
1-12 characters.
Any format allowed for field descriptions in FOCUS.
Default format is D12.2
Any value compatible with the format, or
Any arithmetic expression, or
Any logical expression.
Required to indicate the end of the expression.
;
1. Enter:
? DEFINE
2. The system will respond with:
FILE
FIELD NAME
EMPLOYEE INCREASE
EMPLOYEE BANK_COST
FORMAT
D8.2
F6.2
FIELDNO
36
37
SEGNO
ADDR VIEW
1
00063138
2
00063234
TYPE
IF STATEMENTS
Request:
DEFINE FILE FOCUSEXP
NEWAMT/P10.2=IF ACCTNO IS '10001' THEN AMT * 1.25 ELSE
IF ACCTNO IS '34600' THEN AMT * 2 ELSE
AMT;
END
TABLE FILE FOCUSEXP
SUM NEWAMT AND AMT
BY REGNO
BY COID
BY ACCTT
END
Output:
+----------------------------------------------------------------------+
|PAGE
1
|
|REGION_NO COMPANY_ID ACCOUNT_TYPE
NEWAMT
AMOUNT |
|--------- ---------- ---------------------- |
|01
11701
1
6,654.00
5,404.00
|
|
2
3,000.00
3,000.00
|
|
3
400.00
200.00
|
|
4
-5,200.00
5,200.00 CR |
|02
31702
1
6,530.00
6,505.00
|
|
2
1,025.00
1,025.00
|
|
3
-100.00
50.00 CR |
|
4
-3,450.00
3,450.00 CR |
|03
34608
1
3,050.00
3,000.00
|
|
2
450.00
450.00
|
|
3
-3,150.00
1,575.00 CR |
|
4
-2,300.00
2,300.00 CR |
|
34902
1
738.00
673.00
|
|
2
268.00
268.00
|
|
3
90.00
45.00
|
|
4
-991.00
991.00 CR |
+----------------------------------------------------------------------+
CONCATENATION
Request:
Output:
+----------------------------------------------------------+
|
PAGE
1
|
|
COMPANY_ID NACCT
AMOUNT
|
|
---------- ---------|
|
11701
*10001
5,000.00
|
|
10200
404.00
|
|
*20030
3,000.00
|
|
34600
200.00
|
|
70210
1,000.00 CR
|
|
80301
4,200.00 CR
|
|
31702
10001
100.00
|
|
10003
405.00
|
|
*10200
6,000.00
|
|
20030
1,025.00
|
|
34600
50.00 CR
|
|
80301
3,450.00 CR
|
Request:
Output:
+----------------------------------------------------------+
|
PAGE
1
|
|
NEWNAME
NEWNAME2
|
|
-------------|
|
STEVENS,ALFRED
STEVENS
,ALFR|D
|
SMITH,MARY
SMITH
,MARY|
|
JONES,DIANE
JONES
,DIAN|
|
SMITH,RICHARD
SMITH
,RICH|RD
|
BANNING,JOHN
BANNING
,JOHN|
|
IRVING,JOAN
IRVING
,JOAN|
|
ROMANS,ANTHONY
ROMANS
,ANTH|NY
CHARACTER CONVERSION
Request:
Request:
DEFINE FILE FOCUSEXP
ACCT_GROUP/A12=DECODE ACCTT (1 ASSETS 2 LIABILITIES
'3' 'REVENUE'
'4' 'EXPENSES' ELSE 'ERROR');
END
TABLE FILE FOCUSEXP
PRINT ACCTNO AND AMT
BY ACCT_GROUP
END
Output:
+----------------------------------------------------------+
|
PAGE
1
|
|
ACCT_GROUP
ACCOUNT_NO
AMOUNT
|
|
-----------------------|
|
ASSETS
10001
5,000.00
|
|
10200
404.00
|
|
10200
6,000.00
|
|
10001
260.00
|
|
10003
428.00
|
|
10200
15.00 CR
|
|
EXPENSES
70210
1,000.00 CR
|
|
80301
4,200.00 CR
|
|
80301
3,450.00 CR
|
|
80301
2,300.00 CR
|
|
80301
991.00 CR
|
|
LIABILITIES
20030
3,000.00
|
|
20030
1,025.00
|
|
20030
450.00
|
|
20030
268.00
|
FOR EXAMPLE:
BY ORDERDATE
Sorts dates into date sequence regardless of the display format
DAYS/I4=SHIPDATE-ORDERDATE;
Computes the elapsed number of days between two dates
regardless of their display format.
DAYS/I4=SHIPDATE-'JAN 1 1985'; Computes the elapsed number of days regardless of the
Display format
SHIPMONTH/MONTH=SHIPDATE;
Extracts the month from SHIPDATE
For example if SHIPDATE is December 24,1985, SHIPMONTH IS
12, but would be printed as "DECEMBER".
SHIPMONTH/M=SHIPMONTH + 3;
Always produces a valid month value in the range 1 to 12.
For example, if the value of SHIPMONTH is 12 then
SHIPMONTH + 3 is 3.
SHIPMONTH/YM=SHIPDATE;
The year and month are extracted from shipdate.
In basic date formats, the components are separated by /.The separating character can be
changed.
EXAMPLES:
FORMAT
DISPLAY
__________________________
YMD
Y-M-D
Y.M.D
Y|M|D
YBMBD
85/11/22
85-11-22
85.11.22
851122
85 11 22
MONTH TRANSLATION:
Usage
----MT
Meaning
------short form upper case
Example
------JAN
MTR
JANUARY
,HDT
,YMD
,$
Output:
+----------------------------------------------------------+
|
PAGE 1
|
|
LAST_NAME
DATE OF HIRE
|
|
-------------------|
|
STEVENS
Saturday, June 2 1980
|
|
JONES
Monday, May 1 1980
|
|
BROWN
Saturday, November 25 1985
|
+----------------------------------------------------------+
Masterfile:
FIELDNAME=HIRE_DATE
,HDT
,YMD
,$
Request:
DEFINE FILE EMP50
HIREMO/YM=HIRE_DATE;
HIRED/wrMtrDYY=HIRE_DATE:
END
TABLE FILE EMP50
PRINT LAST_NAME HIREMO AS 'MONTH AND YEAR HIRED'
HIRED as 'DATE OF HIRE' AND
COMPUTE DOS/I4='1985 DEC 31' - HDT; AS 'DAYS,OF,SERVICE' AND
COMPUTE LOS/I4=DOS/30; AS 'MONTHS,OF,SERVICE'
IF HIRE_DATE LT '1985 DEC 31'
END
Output:
+---------------------------------------------------------------------+
|
PAGE 1
|
|
MONTH
DAYS
MONTHS
|
|
AND YEAR
OF
OF
|
| LAST_NAME
HIRED
DATE OF HIRE
SERVICE SERVICE
|
ALIAS=HDT,
FORMAT=I6YMD,
Output:
+---------------------------------------------------------------------+
| PAGE
1
|
| LAST_NAME
FIRST_NAME
LOS1
JOB
NEW_DATE HIRE_DATE |
| ------------------------------ --------- |
|
|
| BANNING
JOHN
153
A17
08/01/82 82/08/01
|
| CROSS
BARBARA
425
A17
11/02/81 81/11/02
|
| MCCOY
JOHN
549
B02
07/01/81 81/07/01
|
| SMITH
MARY
549
B14
07/01/81 81/07/01
|
| STEVENS
ALFRED
943
A07
06/02/80 80/06/02
|
+---------------------------------------------------------------------+
VERB SUMMARY
A REQUEST STATEMENT MAY HAVE UP TO 6 SETS OF VERBS AND ASSOCIATED
SORT CONDITIONS.
NOTE: MUST HAVE SUM BEFORE LIST OR PRINT.
TABLE FILE FOCUSEXP
Request Set 1) SUM AVE.AMOUNT
BY REGION_NO
Request Set 2) PRINT ACCOUNT_NO COST_CENTER
BY REGION_NO
BY COMPANY_ID
END
Output:
+---------------------------------------------------------------------+
|
AVE
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
REGION_NO
--------01
AMOUNT
-----567.33
COMPANY_ID
---------11701
02
671.66
31702
ACCOUNT_NO
---------10001
10200
20030
34600
70210
80301
10001
10003
10200
20030
34600
80301
COST_CENTER|
-----------|
22
|
20
|
19
|
19
|
32
|
29
|
22
|
18
|
20
|
19
|
19
|
29
|
WHEN
Extension of the ON phrase.
Performs conditional printing at break points in a report.
Determines when options such as "ON fieldname SUBTOTAL" appear in the report.
If the WHEN clause is used with SUBHEAD or SUBFOOT, it must be placed on the line
following the text.
ON fieldname option WHEN expression (;)
OPTION:
EXPRESSION:
Request:
WHERE Clause
Allows:
Field to field comparisons
Complex record screens
May replace some DEFINE statements
Syntax:
WHERE <expression> {;}
Field-To-Field Comparison
Request:
DEFINE FILE EMPLOYEE
FLAG/I1=IF CSAL * 1.1 GT 25000
THEN 1 ELSE 0;
END
TABLE FILE EMPLOYEE
PRINT LAST_NAME FIRST_NAME CSAL
BY EID
IF FLAG EQ 1
END
Output:
+-------------------------------------------------------------------+
|
EMP_ID
LAST_NAME
FIRST_NAME
CURR_SAL |
|
----------------------------- |
|
119329144
BANNING
JOHN
$29,700,00 |
|
123764317
IRVING
JOAN
$26,862,00 |
|
818692173
CROSS
BARBARA
$27,062,00 |
+-------------------------------------------------------------------+
Complex Record Screening
Request: TABLE FILE EMPLOYEE
PRINT LAST_NAME FIRST_NAME
CURR_JOBCODE JOBCODE AS 'PREVIOUS'
BY DEPARTMENT BY EMP_ID
WHERE DEPARTMENT EQ 'MIS'
OR CURR_JOBCODE NE JOBCODE
END
Output:
+---------------------------------------------------------------------+
| DEPARTMENT
EMP_ID
LAST_NAME
FIRST_NAME CURR_JOBCODE PREVIOU|
| -------------------------------- ------------ -------|
| MIS
112847612 SMITH
MARY
B14
B14
|
|
117593129 JONES
DIANE
B03
B03
|
|
JONES
DIANE
B03
B02
|
|
219984371 MCCOY
JOHN
B02
B02
|
|
326179357 BLACKWOOD
ROSEMARIE
B04
B04
|
|
543729165 GREENSPAN
MARY
A07
A07
|
|
GREENSPAN
MARY
A07
B01
|
|
818692173 CROSS
BARBARA
A17
A17
|
|
CROSS
BARBARA
A17
A16
|
| PRODUCTION
119265415 SMITH
RICHARD
A01
B01
|
|
123764317 IRVING
JOAN
A15
A14
|
+---------------------------------------------------------------------+
WHERE TOTAL CLAUSE
WHERE screening conditions are applied to values in the internal matrix report.
Rows are eliminated before the report is printed.
Any TRUE/FALSE expression is permitted.
Alphanumeric literals must be enclosed within quotation marks(').
Syntax:
WHERE TOTAL <expression> {;}
Request: TABLE FILE EMPLOYEE
SUM SAL AND AVE.SAL AND COMPUTE PROJ_SAL = LST.SAL * 1.1;
BY EID
WHERE TOTAL SAL GT 30000
OR AVE.SAL GT 20000
OR PROJ_SAL LT 10000
END
Output:
+---------------------------------------------------------------+
|
AVE
|
| EMP_ID
SALARY
SALARY
PROJ_SAL |
| ----------------------- |
| 117593129
$36,230.00
$18,115.00
19.525.00 |
| 119265415
$18,550.00
$9,275.00
9,955.00 |
| 119329144
$29,700.00
$29,700.00
32,670.00 |
| 123764317
$51,282.00
$26,641.00
26,862.00 |
WHERE LIKE Clause
+-------------------------------------------+
|
WHERE field LIKE 'mask|
_____
______
|
WHERE NOT field LIKE 'mas|'
_____
______
+-------------------------------------------+
Used to select records based on pattern matching.
field -- can be any valid alphanumeric fieldname or alias.
'mask' -- Pattern used to match records.
Rules:
Must be enclosed in quotes.
Underscore ( _ ) matches any single character.
Percent ( % ) matches any sequence of characters.
Request:
TABLE FILE CAR
PRINT CAR BODYTYPE BY COUNTRY
WHERE BODYTYPE LIKE '%O%E%'
END
Output:
+-------------------------------------------------------------------+
|
COUNTRY
CAR
BODYTYPE
|
|
---------------|
|
ENGLAND
JAGUAR
CONVERTIBLE
|
|
ITALY
ALFA ROMEO
COUPE
|
|
ALFA ROMEO
ROADSTER
|
|
MASERATI
COUPE
|
+-------------------------------------------------------------------+
QUALIFING FIELDS: WITHIN
Reuqest:
Output:
+----------------------------------------------------------+
|
PCT
|
|
COMPANY_ID ACCOUNT_TYPE
AMOUNT
|
|
---------- ----------------|
|
11701
1
158.75
|
|
2
88.13
|
|
3
5.87
|
|
4
-152.76
|
|
*TOTAL 11701
99.99
|
MATCH COMMAND
File matching is used when data from two different databases is
necessary to produce a single report.
+-------------------------------------------------------------+
|
MATCH FILE EMPLOYEE
|
|
WRITE LAST_NAME FIRST_NAME
|
|
BY JOBCODE
|
|
RUN
|
|
FILE JOBFILE
|
|
WRITE JOB_DESC
|
|
BY JOBCODE
|
|
AFTER MATCH HOLD OLD
|
|
END
|
+-------------------------------------------------------------+
This request will produce a single HOLD file containing the JOBCODE, JOB DESCRIPTION, LAST
NAME and FIRST NAME fields.
Match command can merge up to 6 files in one request
Match cannot use across, total or compute
Match retrieves records from 1st file then 2nd file compares the records based on by's and
verb's
It is important to understand the "one-to-many" relationship.
SUM can generate ONE RECORD FROM MANY while
PRINT copies EACH individual RECORD.
Request 1:
Request 2:
Output 1
+---------------------------------------------------------------+
|PAGE
1
|
|JOBCODE LAST_NAME
FIRST_NAME JOB_DESC
|
|------- ------------------ -------|
|A01
SMITH
RICHARD
PRODUCTION CLERK
|
|A07
GREENSPAN
MARY
SECRETARY
|
|A14
IRVING
JOAN
SUPERVISOR/PRODUCTION
|
|A15
IRVING
JOAN
ASSIST.MANAGER
|
|A16
CROSS
BARBARA
MANAGER
|
|A17
CROSS
BARBARA
DEPARTMENT MANAGER
|
|B01
GREENSPAN
MARY
PROGRAMMER TRAINEE
|
|B02
MCKNIGHT
ROGER
PROGRAMMER
|
|B03
JONES
DIANE
PROGRAMMER ANALYST
|
|B04
BLACKWOOD
ROSEMARIE
SYSTEMS ANALYST
|
|B14
SMITH
MARY
FILE QUALITY
|
+---------------------------------------------------------------+
Output 2
+---------------------------------------------------------------+
|PAGE
1
|
|JOBCODE LAST_NAME
FIRST_NAME JOB_DESC
|
|------- ------------------ -------|
|A01
SMITH
RICHARD
PRODUCTION CLERK
|
|A07
STEVENS
ALFRED
SECRETARY
|
|A07
STEVENS
ALFRED
SECRETARY
|
|A07
GREENSPAN
MARY
SECRETARY
|
|A14
IRVING
JOAN
SUPERVISOR/PRODUCTION
|
|A15
IRVING
JOAN
ASSIST.MANAGER
|
|A16
CROSS
BARBARA
MANAGER
|
|A17
BANNING
JOHN
DEPARTMENT MANAGER
|
|A17
CROSS
BARBARA
DEPARTMENT MANAGER
|
|B01
SMITH
RICHARD
PROGRAMMER TRAINEE
|
|B01
GREENSPAN
MARY
PROGRAMMER TRAINEE
|
|B02
JONES
DIANE
PROGRAMMER
|
|B02
MCCOY
JOHN
PROGRAMMER
|
|B02
MCKNIGHT
ROGER
PROGRAMMER
|
|B02
MCKNIGHT
ROGER
PROGRAMMER
|
|B03
JONES
DIANE
PROGRAMMER ANALYST
|
|B04
ROMANS
ANTHONY
SYSTEMS ANALYST
|
|B04
BLACKWOOD
ROSEMARIE
SYSTEMS ANALYST
|
|B14
SMITH
MARY
FILE QUALITY
|
+---------------------------------------------------------------+
Request:
MATCH FILE EMPLOYEE
SUM LAST_NAME BY EMP_ID
RUN
FILE EDUCFILE
SUM COURSE_CODE BY EMP_ID
AFTER MATCH HOLD OLD
END
TABLE FILE HOLD
PRINT *
END
Output:
+-----------------------------------++----------------------------------+
| EMP_ID
LAST_NAME
COURSE_CODE||EMP_ID
LAST_NAME
COURSE_CODE|
| ------------------------||------------------------|
| 071382660 STEVENS
101
||071382660 STEVENS
101
|
| 112847612 SMITH
103
||112847612 SMITH
103
|
| 117593129 JONES
203
||117593129 JONES
203
|
| 119265415 SMITH
108
||119265415 SMITH
108
|
| 119329144 BANNING
||212289111
103
|
| 123764317 IRVING
||315548712
108
|
| 126724188 ROMANS
||326179357 BLACKWOOD
301
|
| 219984371 MCCOY
||451123478 MCKNIGHT
101
|
| 326179357 BLACKWOOD
301
||818692173 CROSS
302
|
| 451123478 MCKNIGHT
101
||
|
| 543729165 GREENSPAN
||
|
| 818691273 CROSS
302
||
|
+-----------------------------------++----------------------------------+
Request:
MATCH FILE EMPLOYEE
SUM LAST_NAME BY EMP_ID
RUN
FILE EDUCFILE
SUM COURSE_CODE BY EMP_ID
AFTER MATCH HOLD OLD-OR-NEW
END
TABLE FILE HOLD
PRINT *
END
Output:
+-----------------------------------++----------------------------------+
| EMP_ID
LAST_NAME
COURSE_CODE||EMP_ID
LAST_NAME
COURSE_CODE|
| ------------------------||------------------------|
| 071382660 STEVENS
101
||071382660 STEVENS
101
|
| 112847612 SMITH
103
||112847612 SMITH
103
|
| 117593129 JONES
203
||117593129 JONES
203
|
| 119265415 SMITH
108
||119265415 SMITH
108
|
| 119329144 BANNING
||326179357 BLACKWOOD
301
|
| 123764317 IRVING
||451123478 MCKNIGHT
101
|
| 126724188 ROMANS
||818692173 CROSS
302
|
| 212289111
103
||
|
| 219984371 MCCOY
||
|
| 615548712
108
||
|
| 326179357 BLACKWOOD
301
||
|
| 451123478 MCKNIGHT
101
||
|
| 543729165 GREENSPAN
||
|
| 818692173 CROSS
302
||
|
+-----------------------------------++----------------------------------+
Request:
Output:
+---------------------------------------------------------------------+
| PAGE
1
|
|
ACCT
|
| REGION_NO CONAME
AMOUNT
NO
BEDS
|
| --------- ----------- -----|
| 01
HUMANA INC.
3,404.00
6 0000
|
| 02
AUDUBON HOSPITAL
4,030.00
6 0484
|
| 03
GREENBRIER VALLEY HOSPITAL
5.00 CR
6 0122
|
|
RESTON N/P
425.00 CR
6 0000
|
+---------------------------------------------------------------------+
JOIN COMMAND
THE FORMAT OF A SIMPLE JOIN COMMAND
-------------------------------------*************************************************************
JOIN field1 in HOSTFILE TO (ALL) field2 in CRFILE as JOINNAME
*************************************************************
Join command is very similar to a match, however it is much more efficient.
Join does not create a file like match. Just lets you use two files as one.
The format for the two fields specified in the JOIN must be the same.
Up to 16 JOIN commands may be issued for any combination of files.
Join commands are active for current FOCUS session or until you release the connection.
FIELD2 must be indexed. (FIELDTYPE=I)
Join does not always work with sequential files.
The first file is called the 'HOST FILE' and the other is the 'CROSS-REFERENCED FILE'.
Each time FOCUS retrieves a record from the HOST FILE. It then retrieves the records in
the CROSS-REFERENCED FILE containing this value.
Join releases all pre-existing DEFINEd fields for the file being joined.
+-----------------------------------+
|
Check File(filename) Picture
|
+-----------------------------------+
shows the actual structure of the join.
+---------------------------------------------------------------------+
|
JOIN COID IN FOCUSEXP TO COID IN COMASTER AS CDONE
|
|
? JOIN
|
|
CHECK FILE FOCUSEXP PICTURE
|
|
TABLE FILE FOCUSEXP
|
|
SUM AMOUNT
|
|
BY CONAME SKIP-LINE
|
|
BY COID NOPRINT
|
|
BY ACCOUNT_NO
|
|
END
|
+---------------------------------------------------------------------+
DEFINE-based JOIN
----------------In addition to the simple JOIN command, another JOIN syntax is the DEFINE-based JOIN which
allows the field in the host file to be created by a DEFINE statement. The corresponding
field in the cross-referenced file must be a real database field.
The DEFINE command must bE BETWEEN THE JOIN AND TABLE. JOIN'S CLEAR defines. The JOIN
command must fit on one line.
THE FORMAT OF THE DEFINE-based JOIN
----------------------------------************************************************************************
JOIN deffld WITH dbfld in HOSTFILE TO (ALL) field2 in CRFILE as JOINNAME
************************************************************************
EXAMPLE OF THE DEFINED-based JOIN
--------------------------------JOIN ID_NUM WITH CITY IN SALES TO EMP_ID IN EDUCFILE AS SALEDUC
DEFINE FILE SALES
ID_NUM/A9 = DECODE CITY ('NEW YORK' 451123478 'NEWARK' 119265415
COMMAND RECAP
JOIN field1 IN fromfile TO (ALL) field2 IN tofile AS joinname
SUM/WRITE /
\
====> Request fields from both files
COUNT
BY
IF
RUN
SUM/WRITE /
FILE newfile
PRINT
LIST
WINDOWS
Six Different Types
Default is Window Off
To Activate-Window On
Types of Windows
+----------------------+----------------------------------------------+
|Window
| Activity
|
+----------------------+----------------------------------------------+
|
|
|
|Command Window
| Enter FOCUS Commands.
|
+----------------------+----------------------------------------------+
|
|
|
|Output Window
| View Window input and resulting
|
|
| output
|
+----------------------+----------------------------------------------+
|
|
|
|History Window
| See a record of commands entered
|
|
| in the Command Window.
|
+----------------------+----------------------------------------------+
|
|
|
|Help Window
| Display and edit key settings.
|
+----------------------+----------------------------------------------+
|
|
|
|Table Window
| Review output from the previous
|
|
| TABLE request.
|
+----------------------+----------------------------------------------+
|
|
|
|Error Window
| FOCUS error messages.
|
+----------------------+----------------------------------------------+
Command Window
All FOCUS commands are entered at the Command Window.
Up to 4 lines of commands may be entered at a time.
The title area displays the current command mode (TABLE, FOCUS, etc.)
Copied to Output and History Windows.
Submitted for execution.
Output Window
Functions as a session log.
Lines of input are preceded by a caret (>).
Cannot be altered.
History Window
Logs every command entered at the Command Window.
Cursor must be within the history window to view previous commands.
Allows the user to review up to 40 lines entered.
Main FOCUS commands are preceded by caret (>).
Incorrect commands are maintained and preceded by asterisk (*).
Help Window
Displays the PF key settings.
Appears on the screen when:
PF1 key is pressed.
WINDOW HELP is entered on the command line.
To remove from the screen, press PF1 again.
Table Window
Displays the results of the most recent TABLE request.
Holds up to the first 10 pages of report data, to a width of 130 characters.
Use ZOOM (PF2) to view previous results.
Error Window
Appears in the middle to top of the screen when a FOCUS error is generated.
Remains on the screen until the error is corrected.
Cursor positioned in the Command Window at the error.
The part of the command accepted by FOCUS is protected.
After error correction:
PROD.FOCUS.MASTER
FOCUS.USER.MASTER
TEST.FOCUS.MASTER
FOCEXEC
FOCUS.PROD.EXEC
FOCUS.PROD.GENJCL
TEST.FOCUS.EXEC
PROD.FOCUS.EXEC
FOCUS.USER.EXEC
INFOCTR.ID#___.EXEC
HOLDMAST
ID#___.FOCUS.HOLDMAST -
user created schemas. This is the dataset that holds schemas that
are created when requesting data to be held.
- Schema documentation **
- Jcl to submit batch jobs. (Note: All TSO logons have read, write,
and create access to all FOCUS.USER files)
- Procedures library for programs such as FOCPRINT, and LSTPRINT.**
- Dataset which contains software modules necessary to run FOCUS.**
//MASTER
DD DSN=PROD.FOCUS.MASTER,DISP=SHR
//
DD DSN=TEST.FOCUS.MASTER,DISP=SHR
//FOCEXEC DD DSN=TEST.FOCUS.EXEC,DISP=SHR
//
DD DSN=PROD.FOCUS.EXEC,DISP=SHR
//ERRORS
DD DSN=FOCPP.ERRORS,DISP=SHR
//*************************************************************
//HOLDMAST DD DSN=TSOXXX.FOCUS.HOLDMAST,DISP=SHR
//*************************************************************
//HOLD
DD UNIT=SYSDA,SPACE=(TRK,(5,10))
//FOCSORT DD UNIT=SYSDA,SPACE=(TRK,(120,120))
//FOCSTACK DD UNIT=SYSDA,SPACE=(TRK,(20,10),RLSE)
//FOCIDMS DD DSN=INFOCTR.IDMS.ACCESS,DISP=SHR
//
DD DSN=GINFOCTR.IDMS.ACCESS,DISP=SHR
//SYSOUT
DD SYSOUT=*
//OFFLINE DD SYSOUT=*,COPIES=1
//SYSPRINT DD SYSOUT=*
//*********************************************************************
//HOLDNAME DD DSN=TSOXXX.HOLDNAME,
//
DISP=(NEW,CATLG,DELETE),
//
UNIT=SYSDA,
//
SPACE=(TRK,(150,100),RLSE)
//*********************************************************************
//* AFTER THE HOLDFILE IS CREATED THE LRECL AND BLCKSIZE WILL BE
//* ADJUSTED BY FOCUS TO THE ACTUAL LENGTH AND SIZE OF THE FILE
//*********************************************************************
//**************FORMAT USED TO ACCESS THE FILES*******************
//*"SCHEMA" DD DSN="DATASET NAME",DISP=SHR
//*****************************************************************
//**************FOLLOWING FILES THAT ARE TO BE ACCESSED***********
//GLEDGER DD DSN=PRODVSAM.GL.ACCOUNT.MASTER,DISP=SHR
//GLEDRDF DD DSN=PRODVSAM.GL.ACCOUNT.MASTER,DISP=SHR
//SYSIN
DD *
OFFLINE
EX PRGNAME
FIN
/*
ACTUAL & USAGE PARAMETERS
TYPE
I
F
D
P
A
Z
MEANING
LENGTH
1
1
1
1
1
1
USAGE PARAMETERS
OPTION
S
C
B
R
M
N
MDY
YMD
DMY
T
MEANING
Zero Suppress
Comma Edit
Bracket Negatives
Print CR with negatives
Floating dollar sign
Fixed dollar sign
Month/Day/Year (MM/DD/YY)
Year/Month/Day
(YY/MM/DD)
Day/Month/Year (DD/MM/YY)
Translate month into alpha
to
to
to
to
to
to
9
9
16
15
256
15
L
E
MEANING
--------------Average Value
Average Sum of Squares
Minimum Value
Maximum Value
Last Value
First Value
Percent of Column Total
Grand Total
All Occurrences
Sum of the Values
Count of the Values
Subtotal on Subheadings and
Subfootings
Column Total on Subheadings and
Subfootings
MEANING
Displays the fields currently defined for a file.
Lists fields in the master file. (string)
Displays the file directory table.
(ie.?F EMPLOYEE)
?
?
?
?
FILE filename
HOLD
JOIN
n
? SET
? STAT
the last request.