Progress/400
Product Guide
Data Queue Support
Progress/400 allows you to perform operations on data queues from within a Progress client session. You can perform two types of operations:
Using these APIs insulates your code from possible changes to the underlying method of sending and receiving data from data queues and provides a standard interface that will not change. You use them in the same way regardless of whether the code runs from the remote client or from the native clients.
Progress/400 supports the send (create) and receive (find) operations by providing the QDTAQ-ENTRY table definition in the Progress/400 schema. This table is similar to the QCMD table in that it controls the function of the Progress/400 DataServer, but different in that data can be sent to and received from data queues. More than one job can place data onto or receive data from a particular data queue.
NOTE: Do not use the QDTAQ-ENTRY name as a physical file name because the SYNC function updates the file on the client, making the data queue APIs unusable.Before you can place a record onto a data queue, you must create the data queue using the OS/400 Create Data Queue (CRTDTAQ) command. For detailed information about OS/400 data queue access routines, see the IBM OS/400 Control Language Programmer’s Guide and the System API Reference .
The DataServer displays appropriate error messages to the remote client session, with more detailed error information available in the OS/400 job log (assuming that the server is started with logging), or to the native client’s job log, as appropriate.
SEND DATA QUEUE (snddtaqe.p) API
Table 11–17 describes the parameters that you must pass to the SEND DATA QUEUE API. You can use either the same variable names or names of your own choice. Note that you must pass all of these parameters to the API, and they must be in the same order as in Table 11–17.
The following example illustrates calling the SEND DATA QUEUE API from your code:
The OUTPUT parameter can be checked to verify that the entry has been placed on the queue.
To verify that an entry has been changed, check the value of the OUTPUT parameter. Table 11–18 lists possible return values.
Copyright © 2004 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095 |