Report request requirements :-
1) The MFD and the data file must be
set up .
2) A knowledge of the fields in the MFD is
needed as also the format ( usage & actual )
of the fields
, for complex reports ,the format of the data structure structure
must also be
known.
3) The file and the MFD must be accessible
i.e. , one must have proper
access
rights as would the report request stipulate.
TABLE FILE MAST
PRINT AREA SALES1 DATE1 DATE2
END
The output of the focexec is shown below.
AREA SALES1 DATE1
DATE2
------- --------
-------- ---------
HUSTON 111111 98/02/23 00/11/01
CALCUT 888888 98/02/27 00/02/23
BOMBAY 888888 98/03/01 00/02/23
CALCUT 888888 98/03/02 00/02/23
TEXAS 888888 98/03/03
00/02/23
CALCUT 888888 00/02/28 00/02/23
MADRAS 888888 00/02/29 00/02/23
CALCUT 888888 01/03/01 00/02/23
A few other PRINT options.
To print all the fields in the file use the PRINT * option.
To print all the fields in a segment , use the PRINT
SEG.date1
ie, the SEG. followed by any field in that segment.
It terminates a report request.
It processes the report.
It maintains the query environment.
User will see the T>
The file need not be TABLEd again.
LIST Field1
field2
1
value value
2
value value
etc...
The sort fields, if are not needed to be displayed in the report
request can be suppressed with the
noprint option such as :
By date1 noprint
This results in the report being sorted on date1 but date1 is
not displayed.
If another name instead of the Field name is desired in the report
, it can be specified as
By date1 as ‘Start Date’
If the sort order is to be changed to be sorted in an Descending
order ,then
BY HIGHEST DATE1.
SORTING IN GROUPS OF OCCURRENCES.
BY <sortfield> in-groups-of <quantity>
E.g..
TABLE FILE EMPLOYEE
COUNT EID BY SALARY IN-GROUPS-OF 10
END
SALARY
EMPLOYEE-ID
---------
-----------------
0.00
0
5,000
10
15,000
250
25,000
8
50,000
2
AREA
AREA1 AREA2 AREA3 AREA4
-------- -------- --------
--------
1253 1245
6867 3547
6487 7878
9874 3476
Similar to By, here too
ACROSS [ HIGHEST ] sortfield [IN-GROUPS-OF ]
is applicable.
Provides for row and column total in a report request.
Sums the value of each field for each sort value.
Numeric fields are added and alpha fields are overlaid.
If there are no sort fields then the grand total is printed.
E.g..
TABLE FILE EMPLOYEE
TABLE FILE EMPLOYEE
SUM DED_AMT BY EID
SUM DED_AMT
END
END
EMP_ID DED_AMT
DED_AMT
--------- -----------
------------
1234
1,600
51,800
2345
8,000
4671
2,500
8723
1,637
TABLE FILE EMPLOYEE
COUNT CURR_SAL BY DEPT.
END
DEPARTMENT
CURRENT_SAL
COUNT
---------------
-------------------
SOFTWARE
980
HARDWARE
100
MAX
MAXIMUM FIELD VALUE
MAX.SAL
MIN
MINIMUM FIELD VALUE
MIN.SAL
AVE
AVERAGE OF FIELD VALUES
AVE.SAL
PCT
PERCENT OF COLUMN TOTAL
PCT.SAL
RPCT PERCENT
OF ROW TOTAL
RPCT.GROSS
FST
FIRST RETRIVED VALUE
RPCT.SAL
LST
LAST RETRIEVED VALUE.
LST.SAL
CNT
COUNT OF FIELDS RETRIEVED.
CNT.EID
SUM
SUM OF FIELDS RETRIEVED
SUM.SAL
Click here to learn more FOCUS verbs and their usage