Database trace for a target: DBLOOKUP/DBQUERY functions

The following is a selection from a database trace file ( map_name .dbl) for an output card using the GET function to execute a DELETE statement based upon a value in the input.

..Starting a database unload...
Host string: 
Userid     : eventmgt
Password   : ********
Query      : DELETE FROM REGISTRATION WHERE REGISTRATIONSTATUS = 'Overflow'
Query size : 71Output is to a buffer.
Statement execution succeeded.
Retrieved 0 records (0 bytes).
Size of DBLOOKUP data is 0.
Warning returned to engine: (2) No data found
Cleaning up and closing the transaction.....

The following SQL statement to be executed:

DELETE FROM REGISTRATION WHERE REGISTRATIONSTATUS = 'Overflow'

and the resulting successful execution statement:

Statement execution succeeded

are included in this trace file as shown in the example above. Note that no records were retrieved because the DELETE statement does not return data.

The next series of statements are produced for an output card using a DBQUERY function to obtain several columns from a database table based upon specified values in the MEMBERID column in the input data.

..Starting a database unload...
Host string: 
Userid     : eventmgt
Password   : ********
Query      : SELECT FIRSTNAME, LASTNAME , EMAILADDR FROM EVENTMGT.MEMBERSHIP 
             WHERE MEMBERID = 'D191-0001'
Query size : 108
Output is to a buffer.
Statement execution succeeded.
The columns are of the following types:
   Column 1 (FIRSTNAME) type is VARCHAR(30).
   Column 2 (LASTNAME) type is VARCHAR(50).
   Column 3 (EMAILADDR) type is VARCHAR(50).
Number of buffers in fetch array = 492
Writing results to a buffer.
Retrieved 1 records (40 bytes).
Size of DBQUERY data is 40.
The following data was returned from a DBQUERY:

Nancy|Davolio|nancyd@cascadecoffee.com

Status returned to engine: (0) Success
Status returned to engine: (0) Success
Interface library version 6.0(140)
Data being retrieved for DBQUERY function.
Database adapter version 6.0(140)
Starting a database unload...
Host string: Userid     : eventmgt
Password   : ********
Query      : SELECT FIRSTNAME, LASTNAME , EMAILADDR FROM EVENTMGT.MEMBERSHIP 
             WHERE MEMBERID = 'D191-0002'
Query size : 108
Output is to a buffer.
Statement execution succeeded.
The columns are of the following types:
   Column 1 (FIRSTNAME) type is VARCHAR(30).
   Column 2 (LASTNAME) type is VARCHAR(50).
   Column 3 (EMAILADDR) type is VARCHAR(50).
Number of buffers in fetch array = 492
Writing results to a buffer.
Retrieved 1 records (42 bytes).

               Size of DBQUERY data is 42.

               The following data was returned from a DBQUERY:

               Janet|Leverling|jleverling@northwind.com

               .

               .
            

In this example, as in the previous one, the database trace file reports the actual query to be executed. In this example, each DBQUERY returns a single row containing the three columns from the Membership table for the specified MEMBERID. The data returned by the DBQUERY function conforms to the Delimited Row group format type tree definition, meaning that there will be a pipe character (|) delimiter between columns and a carriage return/line feed terminator for each row of data.

The size of the data returned by the DBQUERY is also listed. Note that the size of the DBQUERY data is specified as 42. This value represents the length of the data, including the carriage return/line feed that follows the row of data. There will be a similar set of entries in the database trace file for each DBQUERY executed.