HP 3000 Manuals

Reporting From an HP ALLBASE/SQL Database [ HP ALLBASE/4GL Developer Reference Manual Vol. 1 ] MPE/iX 5.0 Documentation


HP ALLBASE/4GL Developer Reference Manual Vol. 1

Reporting From an HP ALLBASE/SQL Database 

The HP ALLBASE/4GL report generator can be used to create reports from HP
ALLBASE/SQL tables, existing views, or select lists.  To generate a
report from a select list, you must define the select list in the
dictionary.

To generate a report from an HP ALLBASE/SQL database, you must declare
and open a cursor using the SELECT command in an SQL logic block.  You
can use an SQL command in the start-of-report function to call an
appropriate SQL logic block.

The start-of-report function must not contain a FILE *NEXT command after
the SELECT command.  The report generator issues an implicit FILE *FIRST
command while it is creating the report.  This command generates an error
condition if you have already used a FILE *NEXT command.  The FILE *FIRST
command is not permitted for SQL cursors in HP ALLBASE/4GL logic blocks.

If you are generating a report from an HP ALLBASE/SQL select list, the
SQL SELECT statement can perform the selection and sorting required for
the report.  In this case, you will use the HP ALLBASE/4GL report
generator to format and paginate the report.  However, the report
generator's selection and sorting facilities are available to perform any
selection and sorting required in addition to that performed by the
SELECT command.  In general, better reporting performance will be
obtained by using HP ALLBASE/SQL to perform any necessary record
selection and sorting.

File Linkages 

The HP ALLBASE/4GL report generator allows you to define linkages from
SQL objects (base tables, existing views or select lists) to KSAM data
files or HP TurboIMAGE/iX data sets.  However, you cannot define linkages
to SQL tables or select lists, or serial data files.



MPE/iX 5.0 Documentation