How to Use PxPlus Query Definitions in Non-NOMADS Environments

Print a Simple Report

The *TOOLS/QRYPRINT utility can be used to create a formatted PDF report based on a query definition. It can be invoked in your program using the CALL directive:

CALL "*tools/qryprint", queryName$, queryLib$, pdffile$ [, queryopts$, show_flg$, subheader$]

The report has a header consisting of the query title, the date and the page number, which is displayed on each page. An optional sub-header consisting of formatted sub-header lines and optional numeric options (i.e. Total, Average, Minimum and Maximum) can be displayed on the first page of the report.

The body of the report consists of the contents of the query, excluding columns that are defined as hidden in the query definition; however, there is an option to include hidden columns in the report.

Finally, the User ID associated with the session is displayed in the report footer.

Example:

CALL "*tools/qryprint","qClient","panels.en","customer.pdf","C","D"

This code generates a formatted PDF file based on the qClient definition, including numeric calculation options, such as Total, Average, Minimum or Maximum, in the report sub-header. It will also display the PDF file when the report is completed.