AS/400 Report Splitter V4 -...

72
Copyright RJS Software Systems Inc. 1992-2002 AS/400 Report Splitter V4.08 User Guide

Transcript of AS/400 Report Splitter V4 -...

Copyright RJS Software Systems Inc. 1992-2002

AS/400 Report Splitter V4.08User Guide

Table of Contents

Foreword 0

Part I AS/400 Report Splitter 3

................................................................................................................................... 31 Overview

.......................................................................................................................................................... 3Introduction to AS/400 Report Splitter

.......................................................................................................................................................... 4About RJS Software Systems Inc.

.......................................................................................................................................................... 4Licensing Information

.......................................................................................................................................................... 5Contacting RJS Software Systems, Inc.

................................................................................................................................... 52 Installation

.......................................................................................................................................................... 5Introduction to Installation

.......................................................................................................................................................... 5AS/400 Prerequisites for AS/400 Report Splitter

.......................................................................................................................................................... 5AS/400 Installation

.......................................................................................................................................................... 6AS/400 User Authorization Code Entry

.......................................................................................................................................................... 6Deinstallation of AS/400 Report Splitter

................................................................................................................................... 63 Getting Started

.......................................................................................................................................................... 6Introduction to Getting Started

.......................................................................................................................................................... 7Version 4.0 Changes

.......................................................................................................................................................... 7Installing the AS/400 Report Splitter Software

.......................................................................................................................................................... 7Overview of Report Splitting Process

.......................................................................................................................................................... 8How to Run the Report Splitter Process

.......................................................................................................................................................... 9Available Report Splitting Methods

.......................................................................................................................................................... 10Assigning Email Addresses to a Report

.......................................................................................................................................................... 11Flow for Interactively Splitting a Report

.......................................................................................................................................................... 11Flow for Automatic Report Processing

.......................................................................................................................................................... 11Flow for Embedding the Report Splitter Command in a Program

.......................................................................................................................................................... 11Identifying Splitting Criteria within a Report

.......................................................................................................................................................... 12Sample AS/400 Report

.......................................................................................................................................................... 14First Item - Creating Report Page Definition

.......................................................................................................................................................... 16Manually Splitting your First Report

.......................................................................................................................................................... 18Manually Splitting a Report by Page Range

.......................................................................................................................................................... 19Manually Decollating a Report Each Time Criteria Changes

.......................................................................................................................................................... 20Manually Distributing an Entire Report if Selected Criteria Found

.......................................................................................................................................................... 21Manually Distributing a Selected Section of a Report

.......................................................................................................................................................... 23Manually Distributing the Last Page of a Report

.......................................................................................................................................................... 24Setting up Report Distribution Criteria Entries

.......................................................................................................................................................... 24Manually Splitting a Report using Report Distribution Criteria Table

.......................................................................................................................................................... 25Manually Distributing a Report and Embedding an Email Address

.......................................................................................................................................................... 26Automatically Splitting Reports using Output Queue Monitor

.......................................................................................................................................................... 27Embedding Report Splitter Command in User Written Program

.......................................................................................................................................................... 27Running the Report Splitter in a CL Job Stream

.......................................................................................................................................................... 27CL Sample Program Code

.......................................................................................................................................................... 28Creating AS/400 Reports with Unique Spool File Names

.......................................................................................................................................................... 29Merging Multiple Reports into a Single Spool File

.......................................................................................................................................................... 29What's Next After Getting Started?

................................................................................................................................... 294 Available Menus

.......................................................................................................................................................... 29Introduction to Available Menus

.......................................................................................................................................................... 30Getting to the Main Menu

.......................................................................................................................................................... 30Available Options

AS/400 Report Splitter V4.08I

Copyright © 1992-2002 ... RJS Software Systems Inc.

................................................................................................................................... 325 Entering Report Page Definitions

.......................................................................................................................................................... 32Introduction to Entering Report Page Definitions

.......................................................................................................................................................... 32Getting to the Report Page Definition Screen

.......................................................................................................................................................... 33Function Keys

.......................................................................................................................................................... 33Options Available

.......................................................................................................................................................... 34Entry Fields

................................................................................................................................... 376 Entering Report Distribution Settings

.......................................................................................................................................................... 37Introduction to Entering Report Distribution Criteria Settings

.......................................................................................................................................................... 38Getting to the Report Distribution Setting Screen

.......................................................................................................................................................... 38Function Keys

.......................................................................................................................................................... 39Options Available

.......................................................................................................................................................... 39Entry Fields

................................................................................................................................... 477 AS/400 Commands

.......................................................................................................................................................... 47Introduction to AS/400 Commands

.......................................................................................................................................................... 47RPTSPLIT: AS/400 Report Splitter Command

.......................................................................................................................................................... 53RPTMON: Report Splitter Output Queue Monitor

.......................................................................................................................................................... 55WRKSPLIT: Work with Report Splitter

.......................................................................................................................................................... 63RPTMRG: Report Splitter Merge Command

.......................................................................................................................................................... 65RPTNUM: Retrieve Spool File Name/Number

.......................................................................................................................................................... 66RPTREPRINT: Reprint Spool File

.......................................................................................................................................................... 67RJSWRKOUTQ: RJS Work with Output Queue

.......................................................................................................................................................... 68RJSWRKSPLF: RJS Work with Spooled Filesb

................................................................................................................................... 698 Problem Handling

.......................................................................................................................................................... 69Common Errors

.......................................................................................................................................................... 70Other Errors

Index 0

IIContents

II

Copyright © 1992-2002 ... RJS Software Systems Inc.

AS/400 Report Splitter V4.083

Copyright © 1992-2002 ... RJS Software Systems Inc.

1 AS/400 Report Splitter

1.1 Overview

1.1.1 Introduction to AS/400 Report Splitter

The AS/400 Report Splitter is a Native AS/400 Report Distribution application designedto distribute AS/400 reports to local or remote AS/400 users without the necessity of printing.

Utilizing the AS/400 Report Splitter, an entire report or selected portions of a report may be distributed toanother user.

The AS/400 Report Splitter allows a user to:

· Deliver an entire report.· Split and deliver a selected page range.· Scan a report for selected distribution criteria and extract matching pages.· Split a report and create a new spool file each time the selected criteria changes. This is known as

decollating a report.· Scan the header of a report for a selected string value and deliver the entire report if the string is found.· Re-sort pages during reprinting.· Select all pages except the last page.· Select all pages except the last xxx number of pages.· Select only the last page.· Select only the last xxx number of pages.

To facilitate the splitting of selected portions of a report, a level break or comparisondata range must be coded in the report. This string can be up to 30 characters inlength. The Report Splitter will scan the report for the selected comparison datarange when the report is processed.

A report that has been split by the Report Splitter can be automatically distributedto up to ten local output queues and ten remote users when selection criteria isentered at run time. When using the Report Distribution Table, up to 99999 differentselection criteria and destination users can be specified for a report.

The AS/400 Report Splitter's command driven interface makes it easy to integratethe AS/400 Report Splitter into existing applications with minimum effort. The ReportSplitter also has an easy to use "Work With" style spool selection screen to provideusers with easy interactive access to the AS/400 Report Splitter functionality.

The AS/400 Report Splitter also includes an output queue monitor that can monitoran output queue and automatically intercept and distribute selected reports. Theoutput queue monitor program is the best way to automate the entire AS/400 reportdistribution process with the report splitter.

For a more complete electronic report delivery system, the AS/400 Report Splittercan be integrated with any of the RJS electronic report distribution products. Whenintegrated with the other RJS AS/400 report distribution products, reports can beautomatically delivered.

Deliver Reports Using RJS Product(s)

AS/400 Report Splitter 4

Copyright © 1992-2002 ... RJS Software Systems Inc.

Email - WinSpool/400 Email Report Server or Native Email Report Server/400 product

LAN - WinSpool/400 Batch Report Server or Native Batch Report Server/400

CD-ROM - WinSpool/400 Batch Report Server or Lotus Notes Report Server

Internet/Intranet - WinSpool/400 Web Report Server or Web Report Server/400

Lotus Notes/Domino - WinSpool/400 Lotus Notes Report Server or Domino Report Server/400

AS/400 Report Splitter Version 4.0The AS/400 Report Splitter was originally developed back in 1992 before a lot of the newer facilities suchas SQL, ILE, etc. were available for general use on the AS/400. We decided that the technologiesavailable in 2001 would give us the opportunity to better tune the AS/400 Report Splitter by making itfaster and more flexible. The AS/400 Report Splitter Version 4.0 is the culmination of these efforts tocreate a better AS/400 Report Splitter.

AS/400 Report Splitter Version 4.0 FeaturesWhen using the Report Splitter to burst reports, a report is now treated just like a query database. Youdefine the locations on each page that get scanned and the report splitter searches, selects and sortsthe resulting pages into sections based on your selection criteria.

Up to 10 different locations on each page can now be scanned when splitting a report.

Boolean selection criteria can bow be used to select pages from a report. This is similar to using a toolsuch asQuery/400 or SQL/400 to select records.

Pages can be re-sorted during processing.

1.1.2 About RJS Software Systems Inc.

RJS Software is a privately-held software and hardware company dedicated to providing high-qualityAS/400 - iSeries, Client/Server and web-based products and customer services. Customer Service iscentral to the company's objective. Read more about us on our web site.

Copyright1992-2002 by RJS Software Systems Inc. All rights reserved.This manual and the software described

in it are copyrighted with all rights reserved. No part of this publication may be reproduced, transmitted,transcribed, stored in a retrieval system or translated into any language in any form by any meanswithout the written permission of RJS Software Systems.

TrademarksAS/400 Report Splitter ä is a trademark of RJS Software Systems. Brand names and product namesare trademarks or registered trademarks of their respective companies.

1.1.3 Licensing Information

AS/400 Report Splitter is licensed on a per AS/400 partition basis.

The license allows reports to be processed on one licensed AS/400 system.

AS/400 Report Splitter V4.085

Copyright © 1992-2002 ... RJS Software Systems Inc.

1.1.4 Contacting RJS Software Systems, Inc.

For AS/400 Report Splitter technical support, please review the following information before contactingRJS Software Systems.

For Technical Support with AS/400 Report Splitter.Because of the complexity of dealing with the various AS/400 connectivity environments, please gatherand organize as much information as possible on the problem prior to contacting RJS Software Systemsfor support.

If you have a question about an AS/400 Report Splitter operation, first browse through the Online Help totry to find your answer prior to calling RJS Software Systems.

Contact InformationTelephone support is available on normal business days from 9:00 am to 5:00 pm central time.(952) 898-3038 Voice(952) 898-3038 Fax

Support is available via Email at [email protected].

You may also find the answer to your question on our web site: www.rjssoftware.com .

1.2 Installation

1.2.1 Introduction to Installation

This section covers the installation of AS/400 Report Splitter on the AS/400 system that will be runningthe software.

1.2.2 AS/400 Prerequisites for AS/400 Report Splitter

A RISC AS/400 system running V4R2-V5R1 or above is required to run the software.

Note: A non-RISC version of the software for V3R2 can be shipped upon request.

1.2.3 AS/400 Installation

This section includes instructions for restoring the AS/400 Report Splitter AS/400 library.

AS/400 Installation Using RSTLIB CommandInsert the RJS CD into the AS/400 CD Drive and sign on to the AS/400 with a user ID that has securityofficer authority.

Run the following AS/400 command to restore the AS/400 Report Splitter library:RSTLIB SAVLIB(RJSSPLIT) DEV(OPT01) OPTFILE('/RJSSPLIT')

AS/400 Installation Using FTPThis method of installation is described in the RJS Product Catalog and also on the RJS SoftwareSystems installation screen on the RJS CD-ROM.

Note: All web download packages contain an automated FTP upload utility.

AS/400 Report Splitter 6

Copyright © 1992-2002 ... RJS Software Systems Inc.

1.2.4 AS/400 User Authorization Code Entry

Sign on to the AS/400 with a user ID that has security officer authority.

Entering AS/400 Report Splitter Access CodeAdd the RJSSPLIT library to the user library list by typing: ADDLIBLE RJSSPLIT and pressing Enter.

Go to the report splitter menu by typing: GO RJSSPLIT and pressing enter.

From the menu, take option 1.(Enter AS/400 Report Splitter License Code). Type the access codeprovided by RJS Software Systems. Type RJSSPLIT for the data area and the data area library. PressEnter to save the access code.

If you have questions or problems with entering the access codes, contact RJS Software Systems forassistance.

Entering Operating System Specific SettingsAdd the RJSSPLIT library to the user library list by typing: ADDLIBLE RJSSPLIT and pressing Enter.

Go to the report splitter menu by typing: GO RJSSPLIT and pressing enter.

From the menu, take option 2. Enter OS/400 Settings (82=V4R2, 88=V4R3 and above). Enter 88 for thevalue. Press Enter to save the access code.

If you have questions or problems with entering the operating system setting, contact RJS SoftwareSystems for assistance.

1.2.5 Deinstallation of AS/400 Report Splitter

The following sections describe how to remove the AS/400 Report Splitter software from an AS/400system.

Removing AS/400 Report Splitter from an AS/400To remove AS/400 Report Splitter from an AS/400, perform the following individual steps.

Make sure the RJSSPLIT library is not being used.

Sign on to the AS/400 as a security officer.

Delete the RJSSPLIT library from the AS/400 by entering the following command:DLTLIB LIB(RJSSPLIT)

1.3 Getting Started

1.3.1 Introduction to Getting Started

The purpose of this section is to describe how to quickly get started using the AS/400 Report Splittersoftware to electronically deliver AS/400 reports.

AS/400 Report Splitter V4.087

Copyright © 1992-2002 ... RJS Software Systems Inc.

1.3.2 Version 4.0 Changes

The AS/400 Report Splitter was originally developed in 1992 before a lot of the newer AS/400programming tools such as SQL, ILE, etc. were available for use on the AS/400. We decided that takingadvantage of these technologies would give us the opportunity to better tune the AS/400 Report Splitterby making it faster and more flexible. The AS/400 Report Splitter Version 4.0 is the culmination of theseefforts to create a better AS/400 Report Splitter. Because of the changes in AS/400 Report Splitter 4.0,any customer migrating from an older Report Splitter version will need to re-enter their report distributioninformation because the Report Splitter now treats each report like a query database and uses SQL toallow users to enter multiple selection criteria when selecting pages from a report.

AS/400 Report Splitter Version 4.0 Features· When using the Report Splitter to burst reports, a report is now treated just like a query database. You

define the locations on each page that get scanned and the report splitter searches, selects and sortsthe resulting pages into sections based on your selection criteria.

· Up to 10 different locations on each page can now be scanned when splitting a report.

· Boolean selection criteria can bow be used to select pages from a report. This is similar to using a toolsuch as Query/400 or SQL/400 to select records.

· Pages can be re-sorted during processing.

1.3.3 Installing the AS/400 Report Splitter Software

If you haven't installed the software yet, go back to the Installation topic and install the software beforecontinuing.

If you're just reading ahead to find out what to do, then please continue.

1.3.4 Overview of Report Splitting Process

The AS/400 Report Splitter is a Native AS/400 Report Distribution application designed to distributeAS/400 reports to local or remote AS/400 users without the necessity of printing.

Utilizing the AS/400 Report Splitter, an entire report or selected portions of a report may be distributed toanother user.

The AS/400 Report Splitter allows a user to:· Deliver an entire report.· Split and deliver a selected page range.· Scan a report for selected distribution criteria and extract selected pages.· Split a report and create a new spool file each time the selected criteria changes.· Scan the header of a report for a selected string value and deliver the entire report.· Re-sort pages during reprinting.· Select all pages except the last page.· Select all pages except the last xxx number of pages.· Select only the last page.· Select only the last xxx number of pages.

To facilitate the splitting of selected portions of a report, a level break or comparison data range must becoded in the report. This string can be up to 30 characters in length and up to 10 comparison data

AS/400 Report Splitter 8

Copyright © 1992-2002 ... RJS Software Systems Inc.

criteria can be entered for each report page. The Report Splitter will scan the report for the selectedcomparison data when the report is processed and turn the comparison data on each page is extractedinto data fields that can be searched using boolean criteria just like an SQL or Query/400 query woulduse.

Note: When scanning for selected distribution criteria, the criteria must be found on each page that willbe split within a report or the Fill option must be used in the report page definition to tell the splitter toautomatically use the previously selected criteria if the criteria for the current page is blank.

Example: If you want to select all pages from a report where the sales rep = 100, each page for sales rep100 must contain the sales rep number 100. Alternatively if rep 100 is only printed on the first page forthe sales rep 100 section and the Fill option was enabled in the report page defiinition, the splitter willautomatically fill in rep 100 on each subsequent page until the next rep number is found.

A report that has been split by the Report Splitter can be automatically distributed to up to ten localoutput queues and ten remote users when selection criteria is entered at run time.

When using the Report Distribution Table, up to 99999 different selection criteria and destination userscan be specified for each report.

The AS/400 Report Splitter's command driven interface makes it easy to integrate the AS/400 ReportSplitter into existing applications with minimum effort. The Report Splitter also has an easy to use "WorkWith" style spool selection screen to provide users with easy interactive access to the AS/400 ReportSplitter functionality.

The AS/400 Report Splitter also includes an output queue monitor that can monitor an output queue andautomatically intercept and distribute selected reports. The output queue monitor program is the bestway to automate the entire AS/400 report distribution process with the report splitter.

For a more complete electronic report delivery system, the AS/400 Report Splitter can be integrated withany of the RJS electronic report distribution products. When integrated with the other RJS AS/400 reportdistribution products, reports can be automatically delivered.

Deliver Reports Using RJS Product(s)

Email - WinSpool/400 Email Report Server or Native Email Report Server/400 product

PC/LAN Directories - WinSpool/400 Batch Report Server or Native Batch Report Server/400

CD-ROM - WinSpool/400 Batch Report Server or Lotus Notes Report Server

Internet/Intranet - WinSpool/400 Web Report Server or Web Report Server/400

Lotus Notes/Domino - WinSpool/400 Lotus Notes Report Server or Domino Report Server/400

1.3.5 How to Run the Report Splitter Process

The report splitting process can be run using one of the following methods:· Interactively using the Work with Report Splitter Option.· Programmatically using the Report Splitter CL Command.· Automatically via the Output Queue Monitor

AS/400 Report Splitter V4.089

Copyright © 1992-2002 ... RJS Software Systems Inc.

Interactively using Work with Report Splitter OptionUsing the Work with Report Splitter (WRKSPLIT) option, a report can be selected and split interactively.A report is selected by viewing a list of reports from a selected AS/400 output queue and then selectinga report to split from the list.

Programmatically using the Report Splitter CL CommandThe Report Splitter (RPTSPLIT) CL command can be run from the AS/400 command line. The ReportSplitter command can also be embedded into a CL program to allow report splitting to be integrated withany custom AS/400 report creation application.

Automatically via the Output Queue MonitorThe Output Queue Monitor (RPTMON) command can be run during nightly processing to automaticallyprocess all reports from a selected output queue. The output queue monitor can also run in batch all daylong to process and split reports as they are generated. The output queue monitor can also be run fromthe AS/400 job scheduler.

1.3.6 Available Report Splitting Methods

Reports can be split using one of the following methods:· Distribute a Copy of the Entire Report· Distribute a Copy of the Selected Page Range· Decollate a Single Report into Multiple Reports· Scan Report for a String and Distribute a Copy of the Entire Report· Extract Selected Pages Based on Boolean Search Criteria within Report· Distribute only the Last Page of a Report· Distribute a Report using Report Distribution Criteria

Distribute a Copy of the Entire ReportAn entire report can be copied and distributed to one or more AS/400 print queues using the *NOSPLIToption. This is a great way to electronically distribute multiple copies of a single AS/400 report tomultiple users.

Distribute a Copy of the Selected Page RangeA selected number of report pages can be copied and distributed to one or more AS/400 print queuesusing the *PAGERANGE option. This is a great way to distribute selected sections of a report based ona page number range selection.

One use for the page range option is to allow a single report to be printed on multiple printers. Anexample of using this option would be printing an 1000 page report on 2 printers. Pages 1-500 could beprinted on one printer and pages 501-1000 could be printed on another printer.

Decollate a Single Report into Multiple ReportsA single report can be automatically decollated into multiple reports by using the *DECOLLATE option.This is a great way to break a report into sections every time a selected value within a report changes.Many companies create sales reports, commission reports, etc. that are created as a single report, butthey want to break up the report into sections each time the sales rep, sales manager, customer etc.changes. The *DECOLLATE option works well in these scenarios.

Note: When scanning for selected criteria, the criteria must be found on each page that will be splitwithin a report.

Scan Report for a String and Distribute a Copy of the Entire Report

AS/400 Report Splitter 10

Copyright © 1992-2002 ... RJS Software Systems Inc.

Selected columns within a report header can be scanned for a criteria string using the *SCANHDRoption. If the selected string is found within the first few 100 lines of the report, the entire report can bedistributed to the selected report queue.

Extract Selected Pages Based on Boolean Search Criteria within ReportThe *SELECT option can be used to scan a report for up to 10 criteria values. A boolean selectioncriteria can be used to select pages from the report.

Example: (@SALESREP >= 100 and @SALESREP <= 999)

All pages that match the boolean selection criteria will be included when the report is split. This is agreat way to extract a selected portion of a report and distribute the new report electronically to anotheroutput queue, via email etc.

Pages can also be re-sorted in ascending or descending order during spltter processing:

Sort Ascending Example: (@SALESREP >= 100 and @SALESREP <= 999 ORDER BY @SALESREP)

Sort Descending Example: (@SALESREP >= 100 and @SALESREP <= 999 ORDER BY @SALESREPDESC)

Note: When scanning for selected criteria, the criteria must be found on each page that will be splitwithin a report.

Distribute only the Last Page of a ReportThe *LASTPAGE option can be used to distribute only the last page of a selected report. This option isuseful when distributing report information to executives who only need to see report total information.

Distribute a Report using Report Distribution CriteriaThe *TABLE option can be used to distribute a report based on the Report Distribution Criteria table. Upto 99,999 entries can be entered for a particular report. The report distribution criteria are driven by spoolfile name. You will need to make sure your reports are created with unique Spool File Names or UserData names to make sure the report distribution settings will work correctly with a selected report.

Note: See Creating AS/400 Reports with Unique Spool File Names.

1.3.7 Assigning Email Addresses to a Report

If you will be automatically emailing AS/400 reports using the WinSpool/400 Email Report Server or theEmail Report Server/400 product, you can embed an email address within a report using one of thefollowing methods:

· Code the MAILTO: keyword at the beginning of the report or in each report section that will be splitwith the report splitter.

· When setting up a Report Distribution Criteria entry, a report cover page can be created and theMAILTO: keyword can be printed as part of the cover page text.

The Email Report Server will extract the email address from a MAILTO: line and will email the report tothe selected email recipient.

If multiple email addresses are coded in the report, the last email address should be delimited with a

AS/400 Report Splitter V4.0811

Copyright © 1992-2002 ... RJS Software Systems Inc.

tilde ~.

Example email address line with 1 email address: MAILTO: [email protected]

Example multiple email address line: MAILTO: [email protected];[email protected]~

1.3.8 Flow for Interactively Splitting a Report

Sign on to the AS/400 and add the Report Splitter library to your library list using the ADDLIBLERJSSPLIT command.

Type GO RJSSPLIT to go the report splitter main menu.

Take Option 10, Work with Report Splitter to display a list of reports available in a selected outputqueue.

Place an Option 13 next to a report you would like to split and press Enter.

Key in the selected criteria and press Enter to split the report interactively.

1.3.9 Flow for Automatic Report Processing

Reports are generated on an AS/400 and placed into selected output queue(s) so the AS/400 ReportSplitter process can retrieve and split the reports.

The Output Queue Monitor (RPTMON) job is submitted by a user job or the AS/400 job scheduler whenreports are ready to be captured and distributed from a selected output queue. The Output QueueMonitor process can be run once or can be set up to automatically monitor for new reports on a timedinterval.

Most companies run the output queue monitor process once at the end of their nightly report processingso all reports get captured and distributed in one pass at the same time. If multiple source output queueswill be processed, the output queue monitor must be submitted once for each source output queue.

When an output queue gets processed, the Report Distribution Table is checked for the correct splittingcriteria. If criteria are found for a selected report, it is processed and split using the criteria.

After each report is processed it can be automatically marked as sent, deleted, or moved to anotheroutput queue.

1.3.10 Flow for Embedding the Report Splitter Command in a Program

Create a CL program that generates an AS/400 report from a query or RPG program.

After the report program runs, use the RPTNUM command to retrieve the spool file attributes.

Run the Report Splitter (RPTSPLIT) command to split the report using the spool file information retrievedby the RPTNUM command.

See the CL Sample Program Code in one of the next sections for a sample CL program.

1.3.11 Identifying Splitting Criteria within a Report

Before splitting a report that contains selected criteria, you need a quick lesson on how to identify thecorrect report data line and columns when splitting a report. Find a report you want to split by using the

AS/400 Report Splitter 12

Copyright © 1992-2002 ... RJS Software Systems Inc.

AS/400 WRKOUTQ or WRKSPLF command and then open the report for viewing using Option 5.

Sample Report

Since the AS/400 Display Spool File option doesn't show blank lines in the report, follow the steps listedbelow to determine which data line and columns to use when splitting a report.

Display the spool file.

Place a +1 in the Control field and press Enter until the data line to scan on is displayed at the top of thescreen directly under the white ruler line.

Look in the upper right hand corner of the screen to determine the actual line number to scan. In thisexample, we will be scanning line 10 on each page. We will also scan columns1-7 where the customernumber 938,472 is located.

After determining the page line and columns to scan, you are ready to split a report using selectedcriteria.

Note: If you don't correctly determine the actual report data line to scan within a report, your splittingresults may not come out as expected. Always make sure to identify the correct data line and columnrange before attempting to split a report.

1.3.12 Sample AS/400 Report

In this section we will describe the sample report included when the AS/400 Report Splitter software isshipped. We will also describe how to generate the report in an output queue so you can use it to test

AS/400 Report Splitter V4.0813

Copyright © 1992-2002 ... RJS Software Systems Inc.

the AS/400 Report Splitter software.Generating the Sample Report.

Sign on to the AS/400 system and add the RJSSPLIT library to your library list by using the followingAS/400 command: ADDLIBLE RJSSPLIT.

Next type: GO RJSSPLIT and press Enter. This will take you to the AS/400 Report Splitter main menu.

Take Option 4. (Generate Report Splitter Sample AS/400 Report) and select an output queue whereyou would like the sample report to be generated. Press Enter to generate the sample report.

Sample Report CharacteristicsThe report is a sample "Outstanding Invoices" report that is broken up by Sales Rep. The report data isfictional. This report is to be used for learning purposes only.

Sample ReportThe report is broken down as follows:

Sales Rep Data Line LocationLine 3 of every page

Sales Rep Data ColumnsStarting column: 13Ending column: 15

Sales Manager Data Line LocationLine 1 of every page

Sales Manager Data Columns

AS/400 Report Splitter 14

Copyright © 1992-2002 ... RJS Software Systems Inc.

Starting column: 7Ending column: 9

Here is the sample report page sort breakdown by sales rep:Page 1-2, Sales Rep: 100, Manager 001Page 3, Sales Rep: 200, Manager 002Page 4-6, Sales Rep: 300, Manager 003Page 7, Sales Rep: 400, Manager 004Page 8-9, Sales Rep: 100, Manager 005Page 10, Sales Rep: 200, Manager 006Page 11-13, Sales Rep: 300, Manager 007Page 14, Sales Rep: 400, Manager 008

1.3.13 First Item - Creating Report Page Definition

The report page definition is used every time the selected report is split to determine where criteria fieldsare located within each report page.

Before a report can be split for distribution, a report page definition must be created for the report basedon its spool file name. A report page definition tells the report splitter where each of the 10 criteria fieldsare located on each report page. A report page definition has nothing to do with report distributionselection criteria and how a report is split. The report page definition simply tells the splitter how to readeach report page and where the selected criteria is located on each page.

Most reports will have only one report page definition based on the spool file name and *DEFAULT for thetype. This means that there is typically a 1:1 correlation between the AS/400 report and a report pagedefinition. 99.9% of the time each report will only have a single report page definition.

In some situations where reports have a generic spool file name such as QPRINT or QSYSPRT, it maybe necessary to specify the type field based on the program name that created the report or based on auser data, form type or job name value.

Note: The RPTSAMPLE page definition already exists and will be used for the upcoming samples youwill be running. Simply review the report page definition to understand how it works.

Displaying the Report Page Definitions for the RJS Sample ReportSign on to the AS/400 system and add the RJSSPLIT library to your library list by using the followingAS/400 command: ADDLIBLE RJSSPLIT.

Next type: GO RJSSPLIT and press Enter. This will take you to the AS/400 Report Splitter main menu.

Take Option 20. (Edit Report Page Definitions).

The Edit Report Definitions screen will be displayed.

AS/400 Report Splitter V4.0815

Copyright © 1992-2002 ... RJS Software Systems Inc.

Edit Report Page Definitions Screen

Select option 5 to display one of the sample report page definitions.

Report Page Definition Detail

In our example above, there are two fields defined for the selected report:

@REP - This field grabs the sales rep from each page at line 3, columns 13-15. The @REP field can be

AS/400 Report Splitter 16

Copyright © 1992-2002 ... RJS Software Systems Inc.

used on the Edit Report Distribution Setting screen to create a report distribution setting.

@MANAGER - This field grabs the sales manager from each page at line 1, columns 7-9. The@MANAGER field can be used on the Edit Report Distribution Settings screen to create a reportdistribution setting.

Note: Every report must have at least one Report Page Definition created before it can be split. If you aresimply duplicating a report with the *NOSPLIT option, you do not have to define and criteria fields, but thereport page definition must still be created.

1.3.14 Manually Splitting your First Report

Let's begin by manually splitting an entire report to make sure the Report Splitter works correctly.

Sign on to the AS/400 system and add the RJSSPLIT library to your library list by using the followingAS/400 command: ADDLIBLE RJSSPLIT.

Next type: GO RJSSPLIT and press

Enter. This will take you to the AS/400 Report Splitter main menu.

Take Option 4. (Generate Report Splitter Sample AS/400 Report) and select an output queue whereyou would like the sample report to be generated. Press Enter to generate the sample report.

Take Option 10. (Work with Report Splitter) and select the output queue that contains the samplereport you just created.

Once the output queue name has been entered, press Enter and the Work with Report Splitter selectionscreen will be displayed.

AS/400 Report Splitter V4.0817

Copyright © 1992-2002 ... RJS Software Systems Inc.

Work with Report Splitter Report Selection

Place a 13 next to the sample report you want to split. Press Enter and the Report Splitter ParameterSelection prompt will be displayed.

Report Splitter Parameter Selection Screen for *NOSPLIT

Enter the following parameters to split an entire report. The parameters will be explained in more detail inthe reference section:

AS/400 Report Splitter 18

Copyright © 1992-2002 ... RJS Software Systems Inc.

Split Option- *NOSPLIT

Destination output queue/library - A destination output queue where the selected report will beduplicated.

After typing the report information, press Enter to split the report.

Once the report splitter completes, the new report(s) should now exist in the selected destination outputqueue.

Congratulations, you've just split your first report.

1.3.15 Manually Splitting a Report by Page Range

This option will split a report based on a specific selected page range.

Go to the Work with Report Splitter screen and select the sample report for splitting. The Report SplitterParameter Selection screen will be displayed as shown below.

Report Splitter Parameter Selection Screen for *PAGERANGE

Enter the following parameters to split the report by page range. The parameters will be explained inmore detail in the reference section:

Split Option - *PAGERANGE

Page range: 1 - 5

Destination output queue/library - A destination output queue where the selected report will be

AS/400 Report Splitter V4.0819

Copyright © 1992-2002 ... RJS Software Systems Inc.

duplicated.

After typing the report information, press Enter to split the report.

Once the report splitter completes, the new report(s) should now exist in the selected destination outputqueue.

1.3.16 Manually Decollating a Report Each Time Criteria Changes

This option will split a single report into multiple reports every time a selected value within the reportchanges. The reports are split into the same output queue and the user data field for the reports will beset with the criteria for each report section. This allows the resulting reports to be easily distributed withthe RJS Email Report Server, Batch Report Server, Domino Report Server, etc. The Email Report Serverand other products can utilize the user data values to determine where to distribute the resulting reports.

Go to the Work with Report Splitter screen and select the sample report for splitting. The Report SplitterParameter Selection screen will be displayed as shown below.

Report Splitter Parameter Selection Screen for *DECOLLATE

Enter the following parameters to split the report into a new report every time the first field in the ReportPage Definition changes. The parameters will be explained in more detail in the reference section:

Split Option - *DECOLLATE

Destination output queue/library - A destination output queue where the selected report will beduplicated.

After typing the report information, press Enter to split the report.

Once the report splitter completes, the new report(s) should now exist in the selected destination output

AS/400 Report Splitter 20

Copyright © 1992-2002 ... RJS Software Systems Inc.

queue.

1.3.17 Manually Distributing an Entire Report if Selected Criteria Found

This option will scan the selected column range for a specified search string within the first 100 lines ofthe report. If the selected string is found, the entire report will be duplicated and sent to the selectedoutput queue. The search strings are CASE sensitive.

Go to the Work with Report Splitter screen and select the sample report for splitting. The Report SplitterParameter Selection screen will be displayed as shown below.

Report Splitter Parameter Selection Screen for *SCANHDR

AS/400 Report Splitter V4.0821

Copyright © 1992-2002 ... RJS Software Systems Inc.

Report Splitter Parameter Selection Screen 2 for *SCANHDR

Enter the following parameters to search and distribute the entire report if the selected search string isfound within the first 100 report lines.

The parameters will be explained in more detail in the reference section:

Split option - *SCANHDR

Selection criteria - Rep: 100

Destination output queue/library - Enter a destination output queue where the selected report will beduplicated.

After typing the report information, press Enter to split the report.

Once the report splitter completes, the new report(s) should now exist in the selected destination outputqueue.

1.3.18 Manually Distributing a Selected Section of a Report

This option will scan the selected page for a selected criteria value. All pages containing the criteria willbe split into a new report and delivered to the selected output queue(s).

Note: When scanning for selected criteria, the criteria must be found on each page that will be splitwithin a report or the Fill option must be enabled on the report page definition for the selected fields.

Go to the Work with Report Splitter screen and select the sample report for splitting. The Report SplitterParameter Selection screen will be displayed as shown below.

AS/400 Report Splitter 22

Copyright © 1992-2002 ... RJS Software Systems Inc.

Report Splitter Parameter Selection Screen for Selected Criteria

Report Splitter Parameter Selection Screen 2 for Selected Criteria

Enter the following parameters to search and distribute the selection section of a report. The parameterswill be explained in more detail in the reference section:

The parameters will be explained in more detail in the reference section:

AS/400 Report Splitter V4.0823

Copyright © 1992-2002 ... RJS Software Systems Inc.

Split option - *SELECT

Selection criteria - @REP = "100"

Destination output queue/library - Enter a destination output queue where the selected report will beduplicated.

After typing the report information, press Enter to split the report.

Once the report splitter completes, the new report(s) should now exist in the selected destination outputqueue.

1.3.19 Manually Distributing the Last Page of a Report

This option will distribute only the last page of the selected report. The last report page will be split into anew report and delivered to the selected output queue(s). This is a great way to deliver total pages to amanager or other employee/customer who doesn't need to see an entire report.

Go to the Work with Report Splitter screen and select the sample report for splitting. The Report SplitterParameter Selection screen will be displayed as shown below.

Report Splitter Parameter Selection Screen for *LASTPAGE

Enter the following parameters to search and distribute the selection section of a report. The parameterswill be explained in more detail in the reference section:

The parameters will be explained in more detail in the reference section:

Split option - *LASTPAGE

AS/400 Report Splitter 24

Copyright © 1992-2002 ... RJS Software Systems Inc.

Destination output queue/library - Enter a destination output queue where the selected report will beduplicated.

After typing the report information, press Enter to split the report.

Once the report splitter completes, the new report(s) should now exist in the selected destination outputqueue.

1.3.20 Setting up Report Distribution Criteria Entries

See the chapter on Entering Report Distribution Criteria Settings. There are a default set of entriesalready created for the RPTSAMPLE report.

Introduction to Entering Report Distribution Criteria Settings

1.3.21 Manually Splitting a Report using Report Distribution Criteria Table

Manually Splitting a Report using Report Distribution Criteria Table This option will distribute a reportbased on pre-defined report distribution table settings. Up to 99,999 different recipients can be specifiedfor a single report in the report distribution table. When this option is selected, all criteria, including thedestination output queue(s) are selected from the report distribution table. When automating the AS/400Report Splitter processing, you will most likely be using the report distribution criteria Table to hold allreport distribution settings.

Go to the Work with Report Splitter screen and select the sample report for splitting. The Report SplitterParameter Selection screen will be displayed as shown below.

Report Splitter Parameter Selection Screen for *TABLE

Enter the following parameters to use the pre-defined report distribution table settings to distribute areport. The parameters will be explained in more detail in the reference section:

AS/400 Report Splitter V4.0825

Copyright © 1992-2002 ... RJS Software Systems Inc.

The parameters will be explained in more detail in the reference section:

Split option - *TABLE

After typing the report information, press Enter to split the report.

Once the report splitter completes, the new report(s) should now exist in the selected destination outputqueue(s) based on the report distribution setting table.

Note: Remember that when creating Report Distribution Criteria entries, the distribution criteriainformation from the settings table are selected based on spool file name.

Note: The sample entries created for RPTSAMPLE all point to output queue QPRINT in library QGPL.You can change this if necessary by editing the report distribution settings.

1.3.22 Manually Distributing a Report and Embedding an Email Address

This option will distribute an entire report and will create a cover page with an email address on it. This isa nice way to split and email a report to someone via the WinSpool/400 Email Report Server or EmailReport Server/400 software. The WinSpool/400 Email Report Server and Email Report Server/400products also include additional methods for manually mailing an entire report.

Go to the Work with Report Splitter screen and select the sample report for splitting. The Report SplitterParameter Selection screen will be displayed as shown below.

Report Splitter Parameter Selection Screen for Embedding Email Address

Enter the parameters as shown to send out the entire report to the selected output queue. Make sure theoutput queue is a queue that will be monitored by the WinSpool/400 Email Report Server or Email ReportServer/400 software.

AS/400 Report Splitter 26

Copyright © 1992-2002 ... RJS Software Systems Inc.

Press F11 to display the Cover Page Screen. Enter the cover page info as follows. You can use yourown email addresses instead of the sample ones we used. All 5 lines can have a MAILTO: keyword ifnecessary. Our example only uses a single MAILTO: line.

Cover Page Creation

After typing the report information, press Enter to split the report.

Once the report splitter completes, the new report(s) should now exist in the selected destination outputqueue.

They are ready to be processed by the RJS Email Report Server/400 or WinSpool/400 EMail ReportServer software.

1.3.23 Automatically Splitting Reports using Output Queue Monitor

When you're ready to start splitting reports automatically for the first time using the Output QueueMonitor, do the following:

Create all the reports you want to split into a selected output queue. For this example, we will assumethat all of our nightly reports are placed in an output queue called: REPORTS in library QGPL.

Run the following AS/400 command interactively or submit it to batch to run the Output Queue Monitorone time. Once you get comfortable with the concept of using the output queue monitor to processreports, you can set the command up in an AS/400 job scheduler or as part of your nightly processing.

RPTMON FILE(*TABLE) SPLFOPT(*MARK) OUTQ(QGPL/REPORTS) DELAY(*ONCE)

When the command completes, all reports from the REPORTS output queue should be processed andmarked as *SENT in the user data field. The SPLFOPT parameter can also be used to move the reportsto another output queue after being processed or delete them.

AS/400 Report Splitter V4.0827

Copyright © 1992-2002 ... RJS Software Systems Inc.

1.3.24 Embedding Report Splitter Command in User Written Program

By including the AS/400 Report Splitter command within an existing CL program, AS/400 reports can beautomatically distributed to users on the AS/400 as soon as they're created on the system. Thisprevents special intervention to manually distribute a report to an AS/400 user.

1.3.25 Running the Report Splitter in a CL Job Stream

If a job stream is to be set up where the Report Splitter is run right after a new report spool file has beencreated, you can include a call to the Report Splitter command right after the report creation program.Once the report program has completed, the report will be automatically distributed to the selecteddestinations. Following is an example of including the Report Splitter command in aCL  report creation job stream and distributing the report using the Report Distribution Table criteria.

Note: Always use the RPTNUM command to retrieve the original spool file information prior to processingthe report with the Report Splitter command, otherwise the AS/400 Report Splitter may select theincorrect version of the spool file when splitting a report multiple times within the same AS/400 job.

Note: You must also make sure to define all the CL return variables for the RPTNUM command or youmay get a MCHxxxx error when running the RPTNUM command.

Note: You must also make sure to remove all printer overrides with the DLTOVR command before callingthe RPTMON or RPTSPLIT commands, otherwise reports may not get routed correctly to the destinationoutput queue.

1.3.26 CL Sample Program Code

This an example of including the Report Splitter command in a CL report creation job stream anddistributing the report using the Report Distribution Table criteria. This is a great way to split reports asthey are generated.

PGM

/****************************************************************//* DEFINE SPOOL FILE INFORMATION VARIABLES *//****************************************************************/DCL VAR(&SPLFNAME) TYPE(*CHAR) LEN(10)DCL VAR(&JOBNAME) TYPE(*CHAR) LEN(10)DCL VAR(&JOBUSER) TYPE(*CHAR) LEN(10)DCL VAR(&JOBNBR) TYPE(*CHAR) LEN(6)DCL VAR(&SPLNBR) TYPE(*CHAR) LEN(4)

/****************************************************************//* SET UP PRINTER FILE OVERRIDE TO SET USER DATA *//****************************************************************/OVRPRTF FILE(RPT100P) USRDTA(SALES)

/****************************************************************//* PRINT AS/400 REPORT *//****************************************************************/CALL PGM(RPT001)

/****************************************************************//* REMOVE PRINTER OVERRIDE RIGHT AFTER REPORT IS PRINTED */

AS/400 Report Splitter 28

Copyright © 1992-2002 ... RJS Software Systems Inc.

/****************************************************************/DLTOVR FILE(RPT001P)

/****************************************************************//* RETRIEVE ORIGINAL SPOOL INFORMATION FROM REPORT JUST CREATED*//* NOTE: MAKE SURE TO DEFINE ALL RETURN PARAMETERS *//****************************************************************/RPTNUM SPLF(RPT001P) JOB(*) SPLNBR(*LAST) + RTNSPLF(&SPLFNAME) RTNJOBNAME(&JOBNAME) + RTNJOBUSER(&JOBUSER) RTNJOBNUM(&JOBNBR) + RTNSPLNUM(&SPLNBR)

/****************************************************************//* PROCESS ORIGINAL SPOOL FILE WITH THE AS/400 REPORT SPLITTER *//* USING THE REPORT DISTRIBUTION TABLE *//****************************************************************/RPTSPLIT FILE(&SPLFNAME) + JOB(&JOBNBR/&JOBUSER/&JOBNAME) + SPLNBR(&SPLNBR) SPLITOPT(*TABLE)

/****************************************************************//* DELETE ORIGINAL AS/400 SPOOL FILE AFTER PROCESSING *//****************************************************************/DLTSPLF FILE(&SPLFNAME) + JOB(&JOBNBR/&JOBUSER/&JOBNAME) + SPLNBR(&SPLNBR)

ENDPGM

1.3.27 Creating AS/400 Reports with Unique Spool File Names

If you happen to run AS/400 queries or have a lot of reports that get created with QPQUPRFIL, QPRINTor QSYSPRT as the spool file name, the following CL programming technique can be used to ensureyour reports get created with a unique spool file name. Creating unique spool file names will insure thatthe report splitter can process reports correctly.

PGM

/****************************************************************//* CREATE PRINTER OVERRIDE TO CHANGE QUERY SPOOL FILE NAME *//****************************************************************/OVRPRTF FILE(QPQUPRFIL) SPLFNAME(SALES01)

/****************************************************************//* PRINT AS/400 QUERY REPORT *//****************************************************************/RUNQRY QRY(QGPL/SALES01)

/****************************************************************//* REMOVE PRINTER OVERRIDE *//****************************************************************/

AS/400 Report Splitter V4.0829

Copyright © 1992-2002 ... RJS Software Systems Inc.

DLTOVR FILE(QPQUPRFIL)

ENDPGM

The AS/400 query defined above will create a spool file named SALES01 when it gets run.

1.3.28 Merging Multiple Reports into a Single Spool File

If you would like to merge multiple spool files into a single report, use the Report Merge (RPTMRG)command.

1.3.29 What's Next After Getting Started?

You should now have the basics down for manually and automatically splitting AS/400 reports andstaging them to be emailed or archived via other RJS report distribution products. The next few sectionsare a reference for the Report Splitter menu options and each of the AS/400 commands and availableparameters.

Your input is also appreciated to help us keep improving our documentation.

If there's something you would like to see in future versions of the Online Help, send your comments to:[email protected] or give us a call.

1.4 Available Menus

1.4.1 Introduction to Available Menus

This section gives an overview of the AS/400 Report Splitter Main Menu.

AS/400 Report Splitter Main Menu - Options 1-15

AS/400 Report Splitter 30

Copyright © 1992-2002 ... RJS Software Systems Inc.

AS/400 Report Splitter Main Menu - Options 20-33

1.4.2 Getting to the Main Menu

Sign on to the AS/400 system and add the RJSSPLIT library to your library list using the followingAS/400 command: ADDLIBLE RJSSPLIT.

Next type GO RJSSPLIT and press Enter. This will take you to the AS/400 Report Splitter Main Menu.

1.4.3 Available Options

Option 1 – Enter AS/400 Report Splitter License CodeThis menu option is used to enter the AS/400 access code for the AS/400 Report Splitter software. Anaccess code will be provided to you by RJS Software Systems Inc.

Option 2 – Enter OS/400 SettingsThis menu option is used to enter OS/400 version specific settings.Enter 82 if using OS/400 V4R2 or enter 88 if using OS/400 V4R3 or later.

Option 3 – Display Report Splitter Version InfoThis menu option displays the AS/400 Report Splitter version information data area named: VERSION.

AS/400 Report Splitter V4.0831

Copyright © 1992-2002 ... RJS Software Systems Inc.

Option 4 –Generate Report Splitter Sample AS/400 Report - RPTTESTThis menu option is used to create the sample spool file report included with the AS/400 Report Splitter.

Option 10 – Select and Split Reports InteractivelyThis menu option is used to interactively select and split a report from a specific output queue. This isthe best way to split AS/400 reports on an ad-hoc basis.

Option 11 – Run Report Splitter Output Queue Monitor - RPTMONThis menu option is used to submit the output queue monitor to batch or run it interactively. The outputqueue monitor is used to automatically process all the reports from a selected output queue using theReport Distribution Criteria settings.

Option 12 – Submit Report Splitter Output Queue Monitor to BatchThis menu option is used to submit the output queue monitor to batch. The output queue monitor is usedto automatically process all the reports from a selected output queue using the Report DistributionCriteria settings.

Option 13 – Report Splitter Command - RPTSPLITThe Report Splitter command is a CL command used to split AS/400 reports from a user writtenprogram. The Report Splitter command can be embedded into a custom CL, RPG or COBOL program toadd report splitting to user applications.

Option 14 –Report Splitter Spool Merge Command - RPTMRGThe Report Merge command is a CL command used to merge multiple reports from a selected outputqueue into a single spool file. The Report Merge command can be run standalone or embedded into acustom CL, RPG or COBOL program to add report merging to user applications.

Option 15 – Report Splitter Reprint Spool File Utility - RPTREPRINTThe Report Reprint command is a CL utility command used to reprint any AS/400 report manually usingthe selected printer attributes. This command is a utility command provided for the purpose of doing asimple report reprint.

Option 20 – Edit Report Page DefinitionsThis menu option is used to enter AS/400 Report Page Definitions. Each report requires at least onepage definition to be created before the report can be split.

Option 21 – Edit Report Distribution SettingsThis menu option is used to enter AS/400 Report Distribution Settings. Report Distribution settings arethe selection criteria used when splitting a report into multiple sections for multiple recipients.

Option 30 – Build Report Splitter Settings FilesThis menu option is used to build a new set of report splitter setting files if multiple data libraries will beused to store report splitter settings.

Option 31 – Remove Report Splitter Settings FilesThis menu option is used to delete a set of report splitter setting files if they are no longer needed.

Option 32 – Set Report Splitter Debug SettingThis menu option is used to enable or disable the AS/400 Report Splitter debug option.

Option 33 – Run SQL Query StatementsThis menu option is used to run the RPTSQL command which allows interactive SQL statements to berun to display or update records in any AS/400 data file.

AS/400 Report Splitter 32

Copyright © 1992-2002 ... RJS Software Systems Inc.

1.5 Entering Report Page Definitions

1.5.1 Introduction to Entering Report Page Definitions

The report page definition is used every time the selected report is split to determine where criteria fieldsare located within each report page.

Before a report can be split for distribution, a report page definition must be created for the report basedon its spool file name. A report page definition tells the report splitter where each of the 10 criteria fieldsare located on each report page. A report page definition has nothing to do with report distributionselection criteria and how a report is split. The report page definition simply tells the splitter how to readeach report page and where the selected criteria is located on each page.

Most reports will have only one report page definition based on the spool file name and *DEFAULT for thetype. This means that there is typically a 1:1 correlation between the AS/400 report and a report pagedefinition. 99.9% of the time each report will only have a single report page definition.

In some situations where reports have a generic spool file name such as QPRINT or QSYSPRT, it maybe necessary to specify the type field based on the program name that created the report or based on auser data, form type or job name value.

Note: Try to avoid creating multiple page definitions for a single report because it can become confusingvery quickly.

Edit Report Page Definition Main List Screen

1.5.2 Getting to the Report Page Definition Screen

Sign on to the AS/400 system and add the RJSSPLIT library to your library list using the followingAS/400 command: ADDLIBLE RJSSPLIT

AS/400 Report Splitter V4.0833

Copyright © 1992-2002 ... RJS Software Systems Inc.

Next type GO RJSSPLIT and press Enter. This will take you to the AS/400 Report Splitter Report Mainmenu.

Select option 20 to start the program.

1.5.3 Function Keys

Key Function

F3 Exit

F5 Refresh subfile list

F6 Create new record

F8 Paste field values on entry screen

ENTER Accept entry

Page Up/Down Page through available records

1.5.4 Options Available

Option Function

2 Edit existing record.

3 Copy existing record. Use F8 on detail screen to paste copied record into a newrecord.

4 Delete selected record.

5 Display selected record.

AS/400 Report Splitter 34

Copyright © 1992-2002 ... RJS Software Systems Inc.

1.5.5 Entry Fields

Edit Report Page Definition Detail Entry Screen

Page Definition Entry Fields

SpoolEnter the spool file name for the selected report. The spool file name is the main element used toassociate a report page definition with the actual report it will be used with when splitting.

TypeEnter the spool file type for the selected report. The spool file type helps the report splitter processing todetermine which report page definition to use when processing. Any text value can be entered into thetype field, however the text value should correspond to one of the following spool file fields.

99.9% of the time we recommend entering *DEFAULT for the type since most reports will only require asingle report page definition to define the available criteria fields for splitting.

AS/400 Report Splitter V4.0835

Copyright © 1992-2002 ... RJS Software Systems Inc.

Setting Result

*DEFAULT This entry should be used for 99.9% of all reports set up. Entering *DEFAULTis the equivalent of saying that the selected spool file name only has one pagedefinition defined for it and the same page definition and field names will be usedeach time the report is split. This is the easiest situation to use and understand.

Program Name Enter the program name of the RPG or COBOL program that created theselected report if you want to use the spool file name and program name todetermine which report page definition to use when splitting the report.

Example: Let's say several of your reports are created with the same spool filename such as: QSYSPRT. The only way to tell the reports apart is byspecifying the program name value for the type value. In our example here, we'llassume the RPG program that created our report was: RPT100R.

When creating the report page definition we would enter QSYSPRT as the spoolfile name and RPT100R as the type.

When splitting the report with the RPTSPLIT command, we would specify*SPOOL for the report page definition and *PGM or *ALL for the type. Thesplitter would then look for a report page definition based on Spool filename/type: QSYSPRT/RPT100R. If a match was not found for the spoolfile/program name combination, the splitter would next look for a default reportpage definition based on spool file only: QSYSPRT/*DEFAULT.

Note: As mentioned previously, you should try to create 99.9% of all reportpage definitions based on the spool file name only with *DEFAULT as the type.

User Data Enter the user data value for the selected report if you want to use the spool filename and user data value to determine which report page definition to use whensplitting the report.

Example: Let's say several of your reports are created with the same spool filename such as: QSYSPRT. The only way to tell the reports apart is byspecifying the user data value for the type value. In our example here, we'llassume the report was created with a user data value of: STORE100

When creating the report page definition we would enter QSYSPRT as the spoolfile name and STORE100 as the type.

When splitting the report with the RPTSPLIT command, we would specify*SPOOL for the report page definition and *USERDATA or *ALL for the type. Thesplitter would then look for a report page definition based on Spool filename/type: QSYSPRT/STORE100. If a match was not found for the spool/userdata combination, the splitter would next look for a default report page definitionbased on spool file only: QSYSPRT/*DEFAULT.

Note: As mentioned previously, you should try to create 99.9% of all reportpage definitions based on the spool file name only with *DEFAULT as the type.

Form Type Enter the form type value for the selected report if you want to use the spool filename and form type to determine which report page definition to use whensplitting the report.

AS/400 Report Splitter 36

Copyright © 1992-2002 ... RJS Software Systems Inc.

EnabledThis setting determines whether the selected report page definition can be used during report splitterprocessing.

Setting Result

N Enable this report page definition.

Y Disable this report page definition.

Page Definition DescriptionEnter a text description that defines this report page definition. This field is not required. It is forinformation purposes only.

Field Definition(s) - Up to 10 Criteria Fields can be defined for each report

Page LineThis entry field describes the page line from which the selected criteria field will be extracted.

Page Beginning ColumnThis entry field describes the beginning page column from which the selected criteria field will beextracted.

Page Ending ColumnThis entry field describes the ending page column from which the selected criteria field will be extracted.

Field DescriptionEnter a text description that defines this page definition field. This field is not required. It is forinformational purposes only and is used to describe the criteria field.

Symbolic Field NameThis setting determines the field name that will be assigned to the selected criteria at the specified pageline and column position. The symbolic field names must be used when entering report selection criteriain the Edit Report Distribution Settings screen or when a report is being split via the report splittercommand. When assigning symbolic field names, use meaningful names such as @SALESREP,@STORENUMBER, @DEPT, etc.

FillThis setting determines whether a criteria value will be automatically filled in with the previous pagecriteria values when the value is blank during processing.

Example with Fill Enabled: If the fill setting is enabled and you have a report where the first pagecontains rep 100, the second and third pages contain blanks for the rep and the fourth page contains rep200, the rep will automatically be set to rep 100 for pages two and three.

If the selection criteria happens to be for rep 100, pages 1-3 will be selected for splitter processing.

Example with Fill Disabled: If the fill setting is not enabled and you have a report where the first pagecontains rep 100, the second and third pages contain blanks for the rep and the fourth page contains rep200, the rep will not be automatically set for pages two and three.

If the selection criteria happens to be for rep 100, page one will be selected for splitter processing. Pagestwo and three will be omitted because the rep field is blank. Only page one will be selected during thesplitter processing.

AS/400 Report Splitter V4.0837

Copyright © 1992-2002 ... RJS Software Systems Inc.

Setting Result

N The fill option is not activated.

Y The fill option is activated.

ActivatedThis setting determines whether the selected criteria field will be used during report splitter processing.

Setting Result

N The selected field entry is not activated and will not be extracted during reportsplitter processing. This field will not be available for query selection whensplitting a report.

Y The selected field entry is activated and will be extracted during report splitterprocessing. This field will be available for query selection when splitting areport.

1.6 Entering Report Distribution Settings

1.6.1 Introduction to Entering Report Distribution Criteria Settings

This section gives an overview of entering Report Distribution Criteria for selected reports. The ReportDistribution Criteria settings are used to automate report distribution processing.

The Report Distribution Table stores frequently used Report Splitter selection criteria. Once an entry hasbeen made in the distribution table, it can be re-used anytime the Report Splitter command is run with*TABLE entered for the split option.The table can hold up to 99,999 table entries for each spool filename.

The report distribution criteria table is also automatically used when the output queue monitor (RPTMON)is used to process reports.

Report Distribution Settings are based on spool file name and an optional spool file group name.

AS/400 Report Splitter 38

Copyright © 1992-2002 ... RJS Software Systems Inc.

Edit Report Distribution Settings Main List Screen

1.6.2 Getting to the Report Distribution Setting Screen

Sign on to the AS/400 system and add the RJSSPLIT library to your library list using the followingAS/400 command: ADDLIBLE RJSSPLIT

Next type GO RJSSPLIT and press Enter. This will take you to the AS/400 Report Splitter Report Mainmenu.

Select option 21 to start the program.

1.6.3 Function Keys

Key Function

F3 Exit

F5 Refresh subfile list

F6 Create new record

F8 Paste field values on entry screen

ENTER Accept entry

Page Up/Down Page through available records

AS/400 Report Splitter V4.0839

Copyright © 1992-2002 ... RJS Software Systems Inc.

1.6.4 Options Available

Option Function

2 Edit existing record.

3 Copy existing record. Use F8 on detail screen to paste copied record into a newrecord.

4 Delete selected record.

5 Display selected record.

1.6.5 Entry Fields

Report Distribution Criteria Detail Entry Screen 1

SpoolEnter the spool file name for the selected report for which you will be entering criteria.

Spool File GroupThe spool file distribution group is a nice way to separate settings that will be used on a daily basis ormonthly basis, etc.

By default, all entries are assigned to a spool file group of: *DEFAULT.

Example: You could create a group named DAILY for daily reports or MONTHLY for month-end reports.Each group could have different report recipients specified.

The spool file group would then be specified when the RPTSPLIT command is run to split a report orwhen the output queue monitor (RPTMON) is run to automatically split reports.

AS/400 Report Splitter 40

Copyright © 1992-2002 ... RJS Software Systems Inc.

Note: If you're not sure how this setting will benefit your company, simply leave the spool file group fieldvalue set to *DEFAULT when you create new report distribution entries.

Spool File Sequence NumberAn arbitrary sequence number is automatically assigned to each report distribution setting.

ActivatedThis setting determines whether the report distribution criteria setting is activated for report splitterprocessing.

Setting Result

N The distribution criteria entry is not activated.

Y The distribution criteria entry is activated and will be used.

Entry DescriptionThis parameter can be used to enter a meaningful text description for the specified criteria entry. Thedescription if for informational purposes only.

Destination Output Queue/LibraryThe destination output queue can be any existing output queue on the local system. Remote TCP/IPoutput queues can also be created to route reports to other AS/400 systems.

Destination User Identifier/AddressThe destination user identifier can be any valid user id that exists in the AS/400 system directory. Usethe WRKDIR or WRKDIRE command to set up users in the AS/400 system directory. This value is onlyused if running QSNADS on the AS/400 system.

Split OptionThis setting determines how a report is split

AS/400 Report Splitter V4.0841

Copyright © 1992-2002 ... RJS Software Systems Inc.

Setting Result

*NOSPLIT Reprints the entire report. This is a great way to duplicate an entire report tomultiple recipients.

*DECOLLATE Decollates the entire spool file to a single output queue and splits the report intomultiple report sections. A new section is created each time the selectedcriteria field changes. The criteria value is placed into the user data field, so thereports can be uniquely identified. This is a good way to break up a sales reportor any other report into multiple sections every time the selected criteriachanges.

*SELECT Report pages are selected for reprinting based on the boolean selection criteriaentered. The Report Splitter queries the selected fields based on the symbolicfield names set in the report page definition. All selected pages are assembledand placed into a single new spool file. Pages can also be re-sorted duringsplitter processing.

*PAGERANGE Reprints a selected page range. This is a good way to split up a report betweenmultiple printers for printing or reprint selected page numbers.

*LASTPAGE Distributes the last page of a report.

*SCANHDR Scans the first 100 lines of a report for the selected report criteria text valuespecified. If the substring is found anywhere within the first 100 lines of thereport, the entire report will be reprinted.

*TABLE Splits the selected report based on the criteria data specified in the reportdistribution table. Any of the split options above can be specified when entriesare added to the report distribution criteria table.

Completion MessageThis parameter is not currently being used by the AS/400 Report Splitter software.

Audit TrailThis parameter is not currently being used by the AS/400 Report Splitter software.

Use Extended SelectIf this option is enabled, reports will be selectively processed by using any combination of spool filename , user data , user id, job name , form type or the AS/400 program name as a filter to determineif the selected report will be processed. If this option is enabled and a report is found that does not matchone or more of these entries, the report will not be processed by the report splitter.

Setting Result

N Select all reports.

Y Use extended report selection filtering.

PGM - Program That Created Spool FileBecause it is possible for many different report programs to use the same spool file name (Example:QPRINT,QSYSPRT, etc), this parameter is used to differentiate the spool file entries by program name.When a spool file is generated, it contains the program name that created it. The Report Splitter can filterand select spool file entries by the program name. The valid values for this field are *ANY, or the actualprogram name that created the spool file. This parameter must be entered, so *ANY should be used as adefault entry if a spool file is not shared by more than one program. If the program name doesn't matchthe spool file program name or *ANY, the report distribution criteria entry will not by used to process thereport. The report splitter will move on to the next criteria entry.

AS/400 Report Splitter 42

Copyright © 1992-2002 ... RJS Software Systems Inc.

Use the WRKOUTQ or WRKSPLF command Option 8 to view the program name that created a spoolfile.

JobIf the job name entry is specified, the spool file job name will be checked before the report distributioncriteria will be used for processing a particular report. This parameter can be a good way to filter spoolfile selections for the selected report by job name. It's essentially a report filter by AS/400 job name. Ifthe job name doesn't match the spool file job name, the report distribution criteria entry will not by usedto process the report. The report splitter will move on to the next criteria entry.

FormIf the form type entry is specified, the spool file form type will be checked before the report distributioncriteria will be used for processing a particular report. This parameter can be a good way to filter spoolfile selections for the selected report by form type. It's essentially a report filter by AS/400 form type. Ifthe form type doesn't match the spool file form type, the report distribution criteria entry will not by usedto process the report. The report splitter will move on to the next criteria entry.

User DataIf the user data entry is specified, the spool file user data will be checked before the report distributioncriteria will be used for processing a particular report. This parameter can be a good way to filter spoolfile selections for the selected report by user data. It's essentially a report filter by user data. If the userdata value doesn't match the spool file user data, the report distribution criteria entry will not by used toprocess the report. The report splitter will move on to the next criteria entry.

User IDIf the user ID entry is specified, the spool file user ID will be checked before the report distribution criteriawill be used for processing a particular report. This parameter can be a good way to filter spool fileselections for the selected report by user ID. It's essentially a report filter by AS/400 user ID. If the userID value doesn't match the spool file user ID, the report distribution criteria entry will not by used toprocess the report. The report splitter will move on to the next criteria entry.

New Form TypeThis parameter is used to assign the selected form type to the new report created when the selectedreport is processed.

New User DataThis parameter is used to assign the selected user data to the new report created when the selectedreport is processed.

New CopiesThis parameter is used to assign the selected number of print copies to the new report created when theselected report is processed.

New Save StatusThis parameter is used to assign a new save status to the new report created when the selected report isprocessed.

New Output PriorityThis parameter is used to assign a new output priority to the new report created when the selected reportis processed.

New Align Page

AS/400 Report Splitter V4.0843

Copyright © 1992-2002 ... RJS Software Systems Inc.

This parameter is used to assign a new align page status to the new report created when the selectedreport is processed.

New Spool File NameThis parameter is used to assign a new spool file name to the new report created when the selectedreport is processed.

If @VALUE is entered for the new spool file name, the splitter will automatically create the spool filename as follows when splitting the reports with the *DECOLLATE option.

Example: Original spool file name QSYSPRT. Report contains sales rep: 100 and 200. If @VALUE isentered for the new spool file name, each spool file name will be created as follows: R100 and R200. Allspool file names must start with a character, so the first character is always 'R'.

New Hold StatusThis parameter is used to assign a new hold status to the new report created when the selected report isprocessed.

New TextThis parameter is used to assign a new print text value to the new report created when the selectedreport is processed. The print text is a 30-character line of text that can be printer across the bottom ofeach report page.

New Print TextThis parameter is used to determine whether the specified print text is printed on the new report createdwhen the selected report is processed.

New IBM File SeparatorThis parameter is used to assign a new IBM file separator value to the new report created when theselected report is processed. The IBM file separator is a banner page, which prints information about thejob that created a spool file.

Note: The Report Splitter banner page is more appropriate if you want to create a banner page. TheReport Splitter banner page lets you assign up to 5 lines of text to be printed on a report cover page.

New Beginning PageThis parameter is used to determine the new beginning page range assigned to the new report createdwhen the selected report is processed.

Note: Under normal circumstances, the *PAGERANGE option should be used instead of this optionwhich assigns the new page range directly to a spool file. The only time this option should be used is ifan entire report is reprinted and you want to assign a page range directly to the spool file.

New Ending PageThis parameter is used to determine the new ending page range assigned to the new report created whenthe selected report is processed.

Note: Under normal circumstances, the *PAGERANGE option should be used instead of this optionwhich assigns the new page range directly to a spool file. The only time this option should be used is ifan entire report is reprinted and you want to assign a page range directly to the spool file.

New DevThis setting can be used to set the printer device type for the OVRPRTF command used during

AS/400 Report Splitter 44

Copyright © 1992-2002 ... RJS Software Systems Inc.

reprinting.

Setting Result

Blank No change from original spool file.

*SCS SCS text report

*AFPDS AFP report.

*USERASCII User ASCII Report

New Front Overlay/LibraryThis setting can be used to set the front overlay parameter for the OVRPRTF command used duringreprinting. This will apply an AFP overlay automatically when a report is reprinted. This is a nice way toturn regular text reports into AFP documents.

New Front Overlay/LibraryThis setting can be used to set the back overlay parameter for the OVRPRTF command used duringreprinting. This will apply an AFP overlay automatically when a report is reprinted. This is a nice way toturn regular text reports into AFP documents.

Index Field GroupThis parameter is not currently being used by the AS/400 Report Splitter software.

Report Distribution Criteria Detail Entry Screen 2

Banner TextEnter the text to be printed on the banner page when he selected report is split and a banner page is tobe printed. If printing a banner page, the banner page will be printed at the beginning of each reportsection when the report is reprinted. The banner page can be utilized to embed email addresses within areport using the MAILTO: keyword. The MAILTO: keyword can be used by the RJS Email Report Serverproducts to assign email addresses to a report without changing the actual report programming. Banner

AS/400 Report Splitter V4.0845

Copyright © 1992-2002 ... RJS Software Systems Inc.

pages are also a nice way to place a custom message at the beginning of a report.

Example hard coded email address: MAILTO: [email protected]

Example with two email addresses hard coded: MAILTO: [email protected];[email protected]~

Symbolic field values can also be substituted into the cover page during the splitting process.

Example: If you have a symbolic field name called @REP defined in your report page definition and youspecify: Rep Number: @REP for any of the banner page value(s), the cover page value would look asfollows after the new spool file is created for rep 100: Rep Number: 100

Example: Let's say you printed an email address inside the report and wanted to assign the emailaddress into the banner page text, you might key something like the following entry for the banner pagetext value: MAILTO: @EMAILADDR. This sample entry assumes that the report page definition has asymbolic field named: @EMAILADDR defined to extract the email address from the report when split.The resulting cover page value may look like the following: MAILTO: [email protected]

When using the *DECOLLATE split option, the symbolic fields can be a great way to assign uniqueinformation to the banner page from within the first page of each report section.

Print BannerThis setting determines if the report banner page will be printed when a report is split.

Setting Result

N Do not print a banner page.

Y Enable printing of the banner page.

New User Defined DataThis parameter is used to assign the selected user defined data value to the new report created when theselected report is processed.

The used defined data field can be useful to assign email addresses for the RJS Email Report Serverproducts. This field can also be used by user applications as well.

Symbolic field values can be substituted into the cover page during the splitting process.

Example: If you have a symbolic field name called @REP defined in your report page definition and youspecify: Rep Number: @REP for the user defined data value, the user defined data value would look asfollows after the new spool file is created for rep 100: Rep Number: 100

Example: Let's say you printed an email address inside the report and wanted to assign the emailaddress into the user defined data field, you might place something like the following entry for the newuser defined data: MAILTO: @EMAILADDR. This sample entry assumes that the report page definitionhas a symbolic field named: @EMAILADDR defined to extract the email address from the report whensplit. The resulting value may look like the following: MAILTO: [email protected]

AS/400 Report Splitter 46

Copyright © 1992-2002 ... RJS Software Systems Inc.

Report Distribution Criteria Detail Entry Screen 3

Report Selection CriteriaThis screen is used to enter boolean search criteria to determine which pages will be included during thereport splitting process. The report page definition should be checked to determine which symbolic fieldnames can be used on this screen.

Note: Always use double-quotes (") to delimit the criteria values.

Special keyword fields available:@PAGECOUNT - Total number of pahges in the report.@PAGENUM - Current page number.

Example for selecting a single sales rep:@REP = "300"

Example for selecting a list of multiple sales reps:@REP = "300" OR @REP = "100" OR @REP = "400"

Example for selecting a range of sales reps:@REP >= "100" AND @REP <= "400"

Example for selecting a single sales rep for sales manager 001:@REP = "100" and @MANAGER = "001"

Example for selecting the last report page:@PAGENUM = @PAGECOUNT

Example for selecting last two pages of the report:@PAGENUM >= (@PAGECOUNT - 2)

AS/400 Report Splitter V4.0847

Copyright © 1992-2002 ... RJS Software Systems Inc.

Example for selecting all except the last page of the report:@PAGENUM <= (@PAGECOUNT - 1)

Example for selecting all except the last two pages of the report:@PAGENUM <= (@PAGECOUNT - 2)

1.7 AS/400 Commands

1.7.1 Introduction to AS/400 Commands

This section gives an overview of the AS/400 Report Splitter commands.

1.7.2 RPTSPLIT: AS/400 Report Splitter Command

DescriptionThe RPTSPLIT command is the low-level API that gets called to split reports. The RPTSPLIT commandis called automatically from the output queue monitor when automatically splitting reports. TheRPTSPLIT command can also be utilized by user applications to split reports. This command is alsocalled from the WRKSPLIT report selection screen when option 13 is selected to interactively split areport.

Report Splitter Command - RPTSPLIT

Command Parameters

Spool File NameEnter the selected AS/400 spool file name. This information can be determined by using the WRKOUTQcommand to display a report list.

Job Name/User Name/Job Number

AS/400 Report Splitter 48

Copyright © 1992-2002 ... RJS Software Systems Inc.

Enter the selected spool file job name, user name and job number. This information can be determinedby using the WRKOUTQ command to display a report list.

Spool File NumberEnter the selected spool file number. This information can be determined by using the WRKOUTQcommand to display a report list.

Other valid values are *ONLY and *LAST. *ONLY will select the spool file if it's the only spool file in theselected job. *LAST will select the most recent spool file in the selected job.

Report Definition NameThis setting determines which report page definition is used to extract criteria fields from the selectedreport. If *SPOOL is selected, the report page definition will be selected based on the spool file nameand the selected type on the next parameter.

Default value = *SPOOL

Report Definition TypeThis setting determines which report page definition type is used to extract criteria fields from theselected report.

Default value = *ALL

AS/400 Report Splitter V4.0849

Copyright © 1992-2002 ... RJS Software Systems Inc.

Setting Result

*ALL When deciding which report page definition to use, the report splitter command(RPTSPLIT) will use the following search order.

· It will first look for a report page definition based on spool filename/program name .

· If not found, it will look for a report page definition based on spool filename/user data .

· If not found, it will look for a report page definition based on spool filename/form type.

· If not found, it will look for a report page definition based on spool filename/job name .

· If not found, it will look for the default report page definition based on spoolfile name/*DEFAULT.

Note: You should try to create 99.9% of all report page definitions based on thespool file name only with *DEFAULT as the type. This give a 1:1 correlationbetween the spool file name and the field extraction information uses duringrepot splitting.

*PGM When deciding which report page definition to use, the report splitter command(RPTSPLIT) will use the following search order.

· It will first look for a report page definition based on spool filename/program name .

· If not found, it will look for the default report page definition based on spoolfile name/*DEFAULT.

Note: You should try to create 99.9% of all report page definitions based on thespool file name only with *DEFAULT as the type. This give a 1:1 correlationbetween the spool file name and the field extraction information uses duringrepot splitting.

*USERDATA When deciding which report page definition to use, the report splitter command(RPTSPLIT) will use the following search order.

· It will first look for a report page definition based on spool file name/userdata .

· If not found, it will look for the default report page definition based on spoolfile name/*DEFAULT.

Note: You should try to create 99.9% of all report page definitions based on thespool file name only with *DEFAULT as the type. This give a 1:1 correlationbetween the spool file name and the field extraction information uses duringrepot splitting.

*FORMTYPE When deciding which report page definition to use, the report splitter command(RPTSPLIT) will use the following search order.

· It will first look for a report page definition based on spool file name/formtype.

· If not found, it will look for the default report page definition based on spoolfile name/*DEFAULT.

Note: You should try to create 99.9% of all report page definitions based on the

AS/400 Report Splitter 50

Copyright © 1992-2002 ... RJS Software Systems Inc.

Report split option

Setting Result

*NOSPLIT Reprints the entire report. This is a great way to duplicate an entire report tomultiple recipients.

*DECOLLATE Decollates the entire spool file to a single output queue and splits the report intomultiple report sections. A new section is created each time the selectedcriteria field changes. The criteria value is placed into the user data field, so thereports can be uniquely identified. This is a good way to break up a sales reportor any other report into multiple sections every time the selected criteriachanges.

*SELECT Report pages are selected for reprinting based on the boolean selection criteriaentered. The Report Splitter queries the fields based on the symbolic fieldnames set in the report page definition. All selected pages are assembled andplaced into a single new spool file. Pages can also be re-sorted during splitterprocessing.

*PAGERANGE Reprints a selected page range. This is a good way to split up a report betweenmultiple printers for printing.

*LASTPAGE Distributes the last page of a report.

*SCANHDR Scans the first 100 lines of a report for the selected report criteria text valuespecified. If the substring is found anywhere within the first 100 lines of thereport, the entire report will be reprinted.

*TABLE Splits the selected report based on the criteria data specified in the reportdistribution table.Any of the split options above can be specified when entriesare added to the report distribution criteria table.

Report selection criteriaThis screen is used to enter boolean search criteria to determine which pages will be included during thereport splitting process. The report page definition should be checked to determine which symbolic fieldnames can be used on this screen.

Note: Always use double-quotes (") to delimit the criteria values.

Special keyword fields available:@PAGECOUNT - Total number of pahges in the report.@PAGENUM - Current page number.

Example for selecting a single sales rep:@REP = "300"

Example for selecting a list of multiple sales reps:@REP = "300" OR @REP = "100" OR @REP = "400"

Example for selecting a range of sales reps:@REP >= "100" AND @REP <= "400"

Example for selecting a single sales rep for sales manager 001:@REP = "100" and @MANAGER = "001"

Example for selecting the last report page:@PAGENUM = @PAGECOUNT

AS/400 Report Splitter V4.0851

Copyright © 1992-2002 ... RJS Software Systems Inc.

Example for selecting last two pages of the report:@PAGENUM >= (@PAGECOUNT - 2)

Example for selecting all except the last page of the report:@PAGENUM <= (@PAGECOUNT - 1)

Example for selecting all except the last two pages of the report:@PAGENUM <= (@PAGECOUNT - 2)

Starting pageIf *PAGERANGE is selected on the beginning compare data parameter, this is the first page which willbe reprinted.

Ending pageIf *PAGERANGE is selected on the ending compare data parameter, this is the last page which will bereprinted. Up to 9,999,999 pages can be selected.

Destination Output QueueDestination output queue can be any existing output queue on the local system. Up to ten destinationoutput queues can be selected. If *TABLE is selected for the beginning compare data selection, this fieldwill not be displayed on the RPTSPLIT command prompt because all information will be selected fromthe Report Distribution Table.

Destination User IdentifierThe destination user identifier can be any valid SNADS user ID that exists in the AS/400 systemdirectory. Up to ten destination user identifiers can be selected. Most companies will not use SNADSunless they have multiple interconnected AS/400 systems where reports will be sent.If *TABLE is selected for the spool file run option selection, this field will not be displayed on thecommand prompt and the destination user identifier will be determined based on the settings within theReport Distribution Table.Use the WRKDIR or WRKDIRE command to set up users in the AS/400 system directory.

New User Defined DataThis parameter is used to assign the selected user defined data value to the new report created when theselected report is processed.

The used defined data field can be useful to assign email addresses for the RJS Email Report Serverproducts. This field can also be used by user applications as well.

Symbolic field values can be substituted into the cover page during the splitting process.

Example: If you have a symbolic field name called @REP defined in your report page definition and youspecify: Rep Number: @REP for the user defined data value, the user defined data value would look asfollows after the new spool file is created for rep 100: Rep Number: 100

Example: Let's say you printed an email address inside the report and wanted to assign the emailaddress into the user defined data field, you might place something like the following entry for the newuser defined data: MAILTO: @EMAILADDR. This sample entry assumes that the report page definitionhas a symbolic field named: @EMAILADDR defined to extract the email address from the report whensplit. The resulting value may look like the following: MAILTO: [email protected]

New Spool File NameThis parameter is used to assign a new spool file name to the new report created when the selected

AS/400 Report Splitter 52

Copyright © 1992-2002 ... RJS Software Systems Inc.

report is processed.

If @VALUE is entered for the new spool file name, the splitter will automatically create the spool filename as follows when splitting the reports with the *DECOLLATE option.

Example: Original spool file name QSYSPRT. Report contains sales rep: 100 and 200. If @VALUE isentered for the new spool file name, each spool file name will be created as follows: R100 and R200. Allspool file names must start with a character, so the first character is always 'R'.

New User DataThis parameter is used to assign the selected user data to the new report created when the selectedreport is processed.

New Form TypeThis parameter is used to assign the selected form type to the new report created when the selectedreport is processed.

Print BannerThis setting determines if the report banner page will be printed when a report is split.

Setting Result

*NO Do not print a banner page.

*YES Enable printing of the banner page.

Banner TextEnter the text to be printed on the banner page when he selected report is split and a banner page is tobe printed. If printing a banner page, the banner page will be printed at the beginning of each reportsection when the report is reprinted. The banner page can be utilized to embed email addresses within areport using the MAILTO: keyword. The MAILTO: keyword can be used by the RJS Email Report Serverproducts to assign email addresses to a report without changing the actual report programming. Bannerpages are also a nice way to place a custom message at the beginning of a report.

Example hard coded email address: MAILTO: [email protected]

Example with two email addresses hard coded: MAILTO: [email protected];[email protected]~

Symbolic field values can also be substituted into the cover page during the splitting process.

Example: If you have a symbolic field name called @REP defined in your report page definition and youspecify: Rep Number: @REP for any of the banner page value(s), the cover page value would look asfollows after the new spool file is created for rep 100: Rep Number: 100

Example: Let's say you printed an email address inside the report and wanted to assign the emailaddress into the banner page text, you might key something like the following entry for the banner pagetext value: MAILTO: @EMAILADDR. This sample entry assumes that the report page definition has asymbolic field named: @EMAILADDR defined to extract the email address from the report when split.The resulting cover page value may look like the following: MAILTO: [email protected]

When using the *DECOLLATE split option, the symbolic fields can be a great way to assign uniqueinformation to the banner page from within the first page of each report section.

Spool File Distribution Group

AS/400 Report Splitter V4.0853

Copyright © 1992-2002 ... RJS Software Systems Inc.

Spool file distribution group is used to select a Report Distribution Group from the Report DistributionTable when *TABLE is specified for the beginning compare data selection. If this entry is left blank, allentries in the Report Distribution Table that correspond to the selected spool file will be processed.

Validate Directory EntriesIf SNADS users are specified as report recipients, this setting determines whether the AS/400 systemdirectory is checked before reports are split.

Setting Result

*NO The system directory is not checked.

*YES The system directory is checked.

1.7.3 RPTMON: Report Splitter Output Queue Monitor

DescriptionThe Output Queue Monitor is used to automatically monitor for new reports to split. This command canbe run interactively or can be submitted to batch. Typically this option should be submitted to batch torun in job queue QBATCH or QSYSYNOMAX which is part of the QSYSWRK subsystem. Submitting thejob to QSYSNOMAX allows the output queue monitor to run along with other AS/400 server jobs.

Example Output Queue Monitor command being submitted to batch to run once:SBMJOB CMD(RPTMON OUTQ(QGPL/REPORTS) SPLFOPT(*MARK) DELAY(*ONCE)GROUP(*DEFAULT)) JOB(RPTMON)

Example Output Queue Monitor command being submitted to batch to run without ending. It will checkfor new reports every 300 seconds (5 minutes):SBMJOB CMD(RPTMON OUTQ(QGPL/REPORTS) SPLFOPT(*MARK) DELAY(*DELAY) DLYTIM(300)ENDTIME(000000) GROUP(*DEFAULT)) JOB(RPTMON)

Example Output Queue Monitor command being submitted to batch to run until 4:00pm. It will check fornew reports every 300 seconds (5 minutes):SBMJOB CMD(RPTMON OUTQ(QGPL/REPORTS) SPLFOPT(*MARK) DELAY(*DELAY) DLYTIM(300)ENDTIME(160000) GROUP(*DEFAULT)) JOB(RPTMON)

Example Output Queue Monitor command running interactively:RPTMON OUTQ(QGPL/REPORTS) SPLFOPT(*MARK) DELAY(*ONCE) GROUP(*DEFAULT)From the RJSSPLIT menu, take option 11 to run the Output Queue Monitor or option 12 to runin batch.

AS/400 Report Splitter 54

Copyright © 1992-2002 ... RJS Software Systems Inc.

Output Queue Monitor - RPTMON

Command Parameters

Source Output QueueThis parameter is used to select the output queue to be monitored. Only one output queue can bemonitored per instance of the RPTMON command. Multiple instances of the RPTMON command can berun at the same time to monitor multiple output queues.

After Processing Spool OptionThis parameter is used to handle the source spool file after it has been processed by the output queuemonitor.

Setting Result

*DELETE The processed spool file is deleted after processing.

*MARK The processed spool file will be marked with a USRDTA entry of *SENT.

*MOVE The processed spool file will be moved to the output queue specified in theMOVEOUTQ parameter.

*NONE No action is taken after processing the spool file.

Delay Processing or Run OnceEither *DELAY or *ONCE can be selected when running the output queue monitor to have it runcontinuously until a specified time or run only a single time.

Delay Between CyclesThe delay between cycles parameter tells the output queue monitor how long to wait after each cyclewhen running in *DELAY mode. The delay time is specified in seconds. The default value is 300 secondsor 5 minutes between each cycle.

AS/400 Report Splitter V4.0855

Copyright © 1992-2002 ... RJS Software Systems Inc.

Time to End ProgramThis parameter is used to specify an ending time when running in *DELAY mode. The end time is basedon a 24 hour clock from 00:01:00 – 23:59:00 (12:00am – 11:59pm). The default value is 160000, whichwill end the monitor at 4:00pm.

Note: If you specify 000000, the output queue monitor will never end unless the job is ended via theENDJOB command. This setting can be used to run the output queue monitor continuously.

Move to Output QueueThis parameter tells the report monitor the name of an output queue where all processed spool files willbe automatically moved if *MOVE is selected for the after processing spool option. A spool file will onlybe moved if pages are selected for reprinting during the report monitor processing.

Spool File Distribution GroupThis parameter is used to specify a spool file distribution group to use for criteria selection when splittingreports with report monitor. See the Report Splitter command for a definition of the Spool File DistributionGroup parameter. The default value is: *DEFAULT. This will process all entries in the *DEFAULT spoolfile distribution group.

1.7.4 WRKSPLIT: Work with Report Splitter

DescriptionThe WRKSPLIT command can be used to manually select and split reports. This command is handy ifusers will have a need to manually split reports from the AS/400 without running the Output QueueMonitor. This command can be added to user application menus to allow users to access the interactivesplitting functionality of the AS/400 Report Splitter software.

Work with Report Splitter Command Prompt

AS/400 Report Splitter 56

Copyright © 1992-2002 ... RJS Software Systems Inc.

Work with Report Splitter Selection Screen – WRKSPLIT

Command Parameters

Output Queue/LibraryType the selected output queue and library name and press Enter to display the report selection screen.After the Report Selection Screen is displayed, place an Option 13 next to any report if you want to splitit or Option 5 to display the report. When using Option 13, the interactive Report Splitter ParameterSelection screen will be displayed after selecting the option and pressing Enter.

AS/400 Report Splitter V4.0857

Copyright © 1992-2002 ... RJS Software Systems Inc.

Report Splitter Parameter Selection View 1

Report Splitter Parameter Selection View 2

Function Keys

AS/400 Report Splitter 58

Copyright © 1992-2002 ... RJS Software Systems Inc.

Key Function

F3 Exit

F4 Prompt the RPTSPLIT command

F6 Display completed RPTSPLIT command

F8 Submit RPTSPLIT command to batch

F9 Display spool file

F10 AS/400 command entry screen

F11 Display additional parameters (Banner Page Info)

F14 Test Report Distribution criteria settings

ENTER Run RPTSPLIT command on selected report.

Screen Selection Parameters for RPTSPLIT

Spool File NameDisplay only. Automatically filled in by user selection.

Job NameDisplay only. Automatically filled in by user selection.

User NameDisplay only. Automatically filled in by user selection.

Job NumberDisplay only. Automatically filled in by user selection.

Spool File NumberDisplay only. Automatically filled in by user selection.

Split OptionThis setting determines how a report is split

AS/400 Report Splitter V4.0859

Copyright © 1992-2002 ... RJS Software Systems Inc.

Setting Result

*NOSPLIT Reprints the entire report. This is a great way to duplicate an entire report tomultiple recipients.

*DECOLLATE Decollates the entire spool file to a single output queue and splits the report intomultiple report sections. A new section is created each time the selectedcriteria field changes. The criteria value is placed into the user data field, so thereports can be uniquely identified. This is a good way to break up a sales reportor any other report into multiple sections every time the selected criteriachanges.

*SELECT Report pages are selected for reprinting based on the boolean selection criteriaentered. The Report Splitter queries the selected fields based on the symbolicfield names set in the report page definition. All selected pages are assembledand placed into a single new spool file. Pages can also be re-sorted duringsplitter processing.

*PAGERANGE Reprints a selected page range. This is a good way to split up a report betweenmultiple printers for printing or reprint selected page numbers.

*LASTPAGE Distributes the last page of a report.

*SCANHDR Scans the first 100 lines of a report for the selected report criteria text valuespecified. If the substring is found anywhere within the first 100 lines of thereport, the entire report will be reprinted.

*TABLE Splits the selected report based on the criteria data specified in the reportdistribution table. Any of the split options above can be specified when entriesare added to the report distribution criteria table.

Report Definition NameThis setting determines which report page definition is used to extract criteria fields from the selectedreport. If *SPOOL is selected, the report page definition will be selected based on the spool file nameand the selected type on the next parameter.

Default value = *SPOOL

Report Definition TypeThis setting determines which report page definition type is used to extract criteria fields from theselected report.

Default value = *ALL

AS/400 Report Splitter 60

Copyright © 1992-2002 ... RJS Software Systems Inc.

Setting Result

*ALL When deciding which report page definition to use, the report splitter command(RPTSPLIT) will use the following search order.

· It will first look for a report page definition based on spool filename/program name .

· If not found, it will look for a report page definition based on spool filename/user data .

· If not found, it will look for a report page definition based on spool filename/form type.

· If not found, it will look for a report page definition based on spool filename/job name .

· If not found, it will look for the default report page definition based on spoolfile name/*DEFAULT.

Note: You should try to create 99.9% of all report page definitions based on thespool file name only with *DEFAULT as the type. This give a 1:1 correlationbetween the spool file name and the field extraction information uses duringrepot splitting.

*PGM When deciding which report page definition to use, the report splitter command(RPTSPLIT) will use the following search order.

· It will first look for a report page definition based on spool filename/program name .

· If not found, it will look for the default report page definition based on spoolfile name/*DEFAULT.

Note: You should try to create 99.9% of all report page definitions based on thespool file name only with *DEFAULT as the type. This give a 1:1 correlationbetween the spool file name and the field extraction information uses duringrepot splitting.

*USERDATA When deciding which report page definition to use, the report splitter command(RPTSPLIT) will use the following search order.

· It will first look for a report page definition based on spool file name/userdata .

· If not found, it will look for the default report page definition based on spoolfile name/*DEFAULT.

Note: You should try to create 99.9% of all report page definitions based on thespool file name only with *DEFAULT as the type. This give a 1:1 correlationbetween the spool file name and the field extraction information uses duringrepot splitting.

*FORMTYPE When deciding which report page definition to use, the report splitter command(RPTSPLIT) will use the following search order.

· It will first look for a report page definition based on spool file name/formtype.

· If not found, it will look for the default report page definition based on spoolfile name/*DEFAULT.

Note: You should try to create 99.9% of all report page definitions based on the

AS/400 Report Splitter V4.0861

Copyright © 1992-2002 ... RJS Software Systems Inc.

Spool File GroupThis entry determines which spool file group will be used when processing reports. By default the*DEFAULT group will be used. All report distribution criteria entries are automatically assigned to the*DEFAULT group unless otherwise specified.

Page RangeIf *PAGERANGE is selected on the split option parameter, this is the page range which will be reprinted.

Destination Output QueueDestination output queue can be any existing output queue on the local system. Up to ten destinationoutput queues can be selected.

Note: If *TABLE is selected for the split option, this field will not be used. All destination info will beretrieved from the report distribution criteria setttings.

Destination User IdentifierThe destination user identifier can be any valid SNADS user ID that exists in the AS/400 systemdirectory. Up to ten destination user identifiers can be selected. Most companies will not use SNADSunless they have multiple interconnected AS/400 systems where reports will be sent.

Note: If *TABLE is selected for the spool file run option selection, this field will not be used.Use the WRKDIR or WRKDIRE command to set up users in the AS/400 system directory.

Submit Job QueueSelected job queue where report will be split if the job is submitted to batch.

Submit on HoldDetermines whether the job goes on hold when sent to batch.

Setting Result

N Do not submit on hold.

Y Submit job on hold. Must be released from job queue by operator.

If Y is chosen, the job will go on hold in the selected job queue if the job is submitted to batch.

Print BannerThis setting determines if the report banner page will be printed when a report is split.

Setting Result

N Do not print a banner page.

Y Enable printing of the banner page.

Banner TextEnter the text to be printed on the banner page when he selected report is split and a banner page is tobe printed. If printing a banner page, the banner page will be printed at the beginning of each reportsection when the report is reprinted. The banner page can be utilized to embed email addresses within areport using the MAILTO: keyword. The MAILTO: keyword can be used by the RJS Email Report Serverproducts to assign email addresses to a report without changing the actual report programming. Bannerpages are also a nice way to place a custom message at the beginning of a report.

Example hard coded email address: MAILTO: [email protected]

AS/400 Report Splitter 62

Copyright © 1992-2002 ... RJS Software Systems Inc.

Example with two email addresses hard coded: MAILTO: [email protected];[email protected]~

Symbolic field values can also be substituted into the cover page during the splitting process.

Example: If you have a symbolic field name called @REP defined in your report page definition and youspecify: Rep Number: @REP for any of the banner page value(s), the cover page value would look asfollows after the new spool file is created for rep 100: Rep Number: 100

Example: Let's say you printed an email address inside the report and wanted to assign the emailaddress into the banner page text, you might key something like the following entry for the banner pagetext value: MAILTO: @EMAILADDR. This sample entry assumes that the report page definition has asymbolic field named: @EMAILADDR defined to extract the email address from the report when split.The resulting cover page value may look like the following: MAILTO: [email protected]

When using the *DECOLLATE split option, the symbolic fields can be a great way to assign uniqueinformation to the banner page from within the first page of each report section.

Report Selection CriteriaThis screen is used to enter boolean search criteria to determine which pages will be included during thereport splitting process. The report page definition should be checked to determine which symbolic fieldnames can be used on this screen.

Note: Always use double-quotes (") to delimit the criteria values.

Special keyword fields available:@PAGECOUNT - Total number of pahges in the report.@PAGENUM - Current page number.

Example for selecting a single sales rep:@REP = "300"

Example for selecting a list of multiple sales reps:@REP = "300" OR @REP = "100" OR @REP = "400"

Example for selecting a range of sales reps:@REP >= "100" AND @REP <= "400"

Example for selecting a single sales rep for sales manager 001:@REP = "100" and @MANAGER = "001"

Example for selecting the last report page:@PAGENUM = @PAGECOUNT

Example for selecting last two pages of the report:@PAGENUM >= (@PAGECOUNT - 2)

Example for selecting all except the last page of the report:@PAGENUM <= (@PAGECOUNT - 1)

Example for selecting all except the last two pages of the report:@PAGENUM <= (@PAGECOUNT - 2)

AS/400 Report Splitter V4.0863

Copyright © 1992-2002 ... RJS Software Systems Inc.

1.7.5 RPTMRG: Report Splitter Merge Command

DescriptionThe report merge command is used to merge selected report files within a selected output queue into asingle spool file. Some users may want to do this for easier report distribution.

Note: All reports in the source output queue must have the same spool file attributes such as pagelength, width, characters per inch, lines per inch, etc. The attributes from the first spool file selected fromthe source output queue will be used when creating the new spool file during the merge processing.

Report Splitter Merge Command - RPTMRG

Command Parameters

Source Output QueueThis parameter is used to select the source output queue that will be merged into a single spool file.

Destination Output QueueThe destination output queue can be any existing output queue on the local system. Up to tendestination output queues can be selected. The destination output queue will receive the merged spoolfile.

Destination User IdentifierThe destination user identifier can be any valid SNADS user id that exists in the AS/400 systemdirectory. Up to ten destination user identifiers can be selected. Most companies will not use SNADSunless they have multiple interconnected AS/400 systems where reports will be sent.Use the WRKDIR or WRKDIRE command to set up users in the AS/400 system directory.

Print Banner PageIf *YES is selected, a banner page will be printed at the beginning of the report when it is reprinted. If*NO is selected, no banner page will be printed.

AS/400 Report Splitter 64

Copyright © 1992-2002 ... RJS Software Systems Inc.

Banner Page TextUp to 5 lines of text can be specified to print on the banner page if *YES is selected on the Print BannerPage parameter. If you will be emailing reports, you can specify the MAILTO: keyword on any of thebanner page lines to create an embedded email address within the report.Example: MAILTO: [email protected]

Validate Directory EntriesIf SNADS users are specified as report recipients, this setting determines whether the AS/400 systemdirectory is checked before reports are split.

Setting Result

*NO The system directory is not checked.

*YES The system directory is checked.

Select Spool FileIf entered, only reports in the source output queue that match the selected spool file name will beprocessed. This is a good way to limit which reports get included when the report merge process is run.

Select User DataIf entered, only reports in the source output queue that match the selected user data value will beprocessed. This is a good way to limit which reports get included when the report merge process is run.

Select User IDIf entered, only reports in the source output queue that match the selected user id will be processed.This is a good way to limit which reports get included when the report merge process is run.

Select Job NameIf entered, only reports in the source output queue that match the selected job name will be processed.This is a good way to limit which reports get included when the report merge process is run.

Select Form TypeIf entered, only reports in the source output queue that match the selected form type will be processed.This is a good way to limit which reports get included when the report merge process is run.

New Spool FileIf entered, the new spool file created by the report merge process will have the spool file name specified.This is agood way to provide unique spool file names for new reports created by the report merge process.

New User DataIf entered, the new spool file created by the report merge process will have the user data specified. Thisis a good way to provide unique user data for new reports created by the report merge process.

New Form TypeIf entered, the new spool file created by the report merge process will have the form type specified. Thisis a good way to provide unique form types for new reports created by the report merge process.

After Processing Spool OptionThis parameter is used to handle the source spool file after it has been processed by the report mergeprocess.

AS/400 Report Splitter V4.0865

Copyright © 1992-2002 ... RJS Software Systems Inc.

Setting Result

*DELETE The processed spool file is deleted after processing.

*MARK The processed spool file will be marked with a USRDTA entry of *SENT.

*MOVE The processed spool file will be moved to the output queue specified in theMOVEOUTQ parameter.

*NONE No action is taken after processing the spool file.

Move to Output QueueThis parameter tells the report merge process the name of an output queue where all processed spoolfiles will be automatically moved if *MOVE is selected for the after processing spool option. A spool filewill only be moved if pages are selected for reprinting during the report merge processing.

1.7.6 RPTNUM: Retrieve Spool File Name/Number

DescriptionThe RPTNUM command can be utilized by user applications to retrieve the spool file job information for aselected report before it's split with the RPTSPLIT command.

Retrieve Spool File Name/Number - RPTNUM

Command Parameters

Spool File NameEnter the selected AS/400 spool file name. This information can be determined by using the WRKOUTQcommand to display a report list.

Job Name/User Name/Job NumberEnter the selected spool file job name, user name and job number. This information can be determinedby using the WRKOUTQ command to display a report list.

AS/400 Report Splitter 66

Copyright © 1992-2002 ... RJS Software Systems Inc.

Spool File NumberEnter the selected spool file number. This information can be determined by using the WRKOUTQcommand to display a report list.

Other valid values are *ONLY and *LAST. *ONLY will select the spool file if it's the only spool file in theselected job. *LAST will select the most recent spool file in the selected job.

Return Spool FileThis parameter will return a 10-character spool file name for the selected spool.

Return Job NameThis parameter will return a 10-character job name for the selected spool.

Return Job UserThis parameter will return a 10-character user name for the selected spool.

Return Job NumberThis parameter will return a 6-character job number for the selected spool.

Return Spool NumberThis parameter will return a 4-character spool file number for the selected spool.

1.7.7 RPTREPRINT: Reprint Spool File

DescriptionThe reprint spool file command can be used to reprint a spool file with different print attributes. This maysometimes be necessary if a report was printed with the wrong CPI (characters per inch) setting or withany other invalid printer attribute. The RPTREPRINT command is an AS/400 Report Splitter utilitycommand.

AS/400 Report Splitter V4.0867

Copyright © 1992-2002 ... RJS Software Systems Inc.

Reprint Report Command - RPTREPRINT

Command Parameters

Spool File NameEnter the selected AS/400 spool file name. This information can be determined by using the WRKOUTQcommand to display a report list.

Job Name/User Name/Job NumberEnter the selected spool file job name, user name and job number. This information can be determinedby using the WRKOUTQ command to display a report list.

Spool File NumberEnter the selected spool file number. This information can be determined by using the WRKOUTQcommand to display a report list.

Other valid values are *ONLY and *LAST. *ONLY will select the spool file if it's the only spool file in theselected job. *LAST will select the most recent spool file in the selected job.

Change Printer AttributesIf *YES is selected, the AS/400 OVRPRTF (Override with Printer File) command will be prompted forbefore the spool file is reprinted. Any allowable parameter on the OVRPRTF command may be changedso the report is reprinted with the selected printer attributes.

If *NO is selected, the report is reprinted with the same printer attributes.

1.7.8 RJSWRKOUTQ: RJS Work with Output Queue

DescriptionThe RJS Work with Output Queue command can be used as a replacement for the Work with OutputQueue command: WRKOUTQ. The command displays a list of reports for the selected output queue andalso has options available for emailing a report, converting a report, faxing a report or splitting a reportwith the Report Splitter.

AS/400 Report Splitter 68

Copyright © 1992-2002 ... RJS Software Systems Inc.

RJS Work with Output Queue

Command Parameters

Output Queue/LibraryType the selected output queue and library name and press Enter to display the report selection screen.

1.7.9 RJSWRKSPLF: RJS Work with Spooled Filesb

DescriptionThe RJS Work with Spooled Files command can be used as a replacement for the Work with SpooledFiles command: WRKSPLF. The command displays a list of reports for the selected user and also hasoptions available for emailing a report, converting a report, faxing a report or splitting a report with theReport Splitter.

AS/400 Report Splitter V4.0869

Copyright © 1992-2002 ... RJS Software Systems Inc.

RJS Work with Spooled Files

Command Parameters

UserType the selected user name or leave the default of *CURRENT to display a report list for the currentuser.

Output QueueType the selected output queue to filter the report list by output queue.

Form TypeType the selected form type to filter the report list by form type.

User DataType the selected user data if you want to filter the report list by user data.

1.8 Problem Handling

1.8.1 Common Errors

· If you get an error when running the output queue monitor, make sure to review the Entering OperatingSystem Specific Settings section in the Installation section of the Online Help and run the RPTOScommand in the RJSSPLIT directory to make sure the API length is set correctly.

· If you are using a special keyword such as *DECOLLATE, *NOSPLIT, *PAGERANGE, etc. and thereport doesn't split correctly, make sure the keywords are being typed using capital letters. All of thespecial keywords are CASE sensitive.

· If you are splitting a report using specific selection criteria and the report does not split, make sure to

AS/400 Report Splitter 70

Copyright © 1992-2002 ... RJS Software Systems Inc.

use the WRKOUTQ or WRKSPLF commands to select and view the report and verify that the pageline you're scanning on is correct.Also, see the Getting Started section for instructions on how toidentify page/line breaks within a report.

· All return values for RPTNUM need a variable assigned to them. See the CL sample program in theGetting Started section.

· If a report is not going to the correct output queue when it gets reprinted, make sure all print overrideshave been removed prior to calling the Report Splitter processing. Any time an OVRPRTF command isused it should be followed with a DLTOVR command immediately after the report is generated, butbefore the Report Splitter processing is called. You can also use the DSPOVR command to displayprinter overrides for an interactive AS/400 job.

1.8.2 Other Errors

If you cannot resolve the problem you're experiencing by using the previous troubleshooting methods,you should contact RJS  Software Systems for advice.

Back Cover