Getting Started with TRANSACT (32247-90007)
117
8 Special Topics
Interface to Report/V
In previous sections, we looked at examples of using Transact as a report generator. These
examples illustrated features of Transact but were not meant to indicate that one of the
strengths of Transact is its report writing capability.
In fact, Transact is not meant to be a report writer. Although some high level benefits are
gained, most reporting controls, like sort control breaks and subtotals, still have to be
coded in Transact. This is where Report/V can help out.
Report/V is a report writer. It can be run as a free standing program and most times this is
the way it is run.
However for complex reporting needs, combining Transact and Report/V will solve the
problem. Transact can be used to extract the data and do the data manipulation creating a
file which is then given to Report/V to generate the report.
The following example illustrates a typical Transact solution to a complicated reporting
requirement. For those of you who use report writers, think about what you would have to
do if you needed to prepare a report like this. If the report writer you are familiar with
could prepare this report, the chances are it would consist of several intermediate passes
over the data before the final report could be generated.
More typically, you would have to do the data extraction and manipulation using a
language like COBOL and would probably let COBOL create the report, since interfacing
to a report writer at that point would be difficult.
The example consists of preparing a backorder report. Our database maintains inventory
of each part-number by location code. Thus it is possible that there are many records to
add up to compute the total inventory on hand for a part. Likewise, there may be many
orders for the same part-number. For illustration purposes, inventory is arbitrarily
allocated to orders based upon the order-date. Thus, the backlog report will identify which
orders or parts of an order can be filled from inventory and which can only be filled from
future production.
Assume that the database contains the following inventory and order information.