Release 10.1A: OpenEdge Reporting:
Report Builder Deployment

> ## Table interface quick start example

> As described in the "Table interface basics" section, there are three steps you must perform to use this interface. The first step in this example is to create the Report Engine table in a new or existing database. Use the `rbreport.df` definition file to get started more easily with the interface. The file contains loadable definitions for the RBREPORT table. The second step is to create a record in the table and set some of the fields in that record, and the third step is to invoke Report Engine. The `rbstart1.p` procedure performs the second and third tasks as an example.

> | To create the Report Engine table using the rbreport.df file, and then invoke Report Engine using it:

> 1. Create a database called Runtable containing the Report Engine table. You can use the database definition file (`%DLC%\bin\rbreport.df`) that contains loadable definitions for the RBREPORT table. (Note that you can give the database any name you choose, and it can contain other tables, such as the tables that contain your report data.)

> 2. Create an MS-Windows icon with the following command on the command line:

>     wproserv -db dbname

> Note that `dbname` contains the full pathname of the Runtable database.

> 3. Double-click the MS-Windows icon to start the database server. The icon becomes minimized.

> 4. Start the Procedure Editor and connect to the Runtable database in multi-user mode.

> 5. Run the `rbstart1.p` procedure.

> Here is the code for the `rbstart1.p` procedure:

> rbstart1.p
>       DO TRANSACTION:

>     /* 1 */
>       CREATE RBREPORT.

>     /* 2 */
>       ASSIGN
>         RBREPORT.RB-REPORT-LIBRARY = "c:\dlc\src\aderb\rbsample.prl"
>         RBREPORT.RB-REPORT-NAME = "Customer Discount"
>         RBREPORT.RB-PRINT-DESTINATION = "D"
>         RBREPORT.RB-DISPLAY-STATUS = yes
>         RBREPORT.RB-DISPLAY-ERRORS = yes.

>       RELEASE RBREPORT.

>       END.

>     /* 3 */
>       RUN aderb\_prore(false, "-db Runtable -S servername -H hostname
>         -N networktype -rbdel").

> The commented numbers correspond to the following step-by-step descriptions:

> 1. Create an RBREPORT record.

> 2. Enter the values for five of the record fields. Report Engine uses the default values for the fields for which you do not specify a value.

> 3. Call the `_prore.p` procedure to invoke Report Engine and specify the `NO-WAIT-value` and the database connection information. By specifying “`false`” as the `NO-WAIT-value`, you instruct the `_prore.p` procedure to wait until Report Engine completes processing before continuing with the application. Finally, the Report Delete (`-rbdel`) parameter deletes the record from the Report Engine table when the procedure is done.

> See the "Methods of invoking Report Engine" section for more information about the `_prore.p` procedure.

Copyright © 2005 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095