HP NonStop G-Series User Manual
Page 75

Application Design Considerations
Creating Client Applications
110838 Tandem Computers Incorporated
4–19
previous read transaction), then puts these fields into the old record portion of an
update transaction message. When the server compares (at the data group level) the
old message record and the record read from the database, there could be differences.
For most cases, the Tandem DDE Gateway remedies this situation by automatically
initializing the buffers (in the Tandem DDE Gateway) to binary zeros. Thus, implied
filler in messages is always binary zero. Your application might therefore encounter
difficulties only when updating a database record (that was previously maintained by
other Tandem applications or requesters) for the very first time.
Note
Tandem servers that update transactions often require that both old and new record images be sent in the
update request message. The key from the old record image is used by the Tandem server to read the
database, then the old record image is compared to the database record image to see if the database
record was updated since the issuer of the update transaction read it.
DDE Poke and DDE
Request of Group Data
Elements
The Tandem DDE Gateway Dictionary, created by the Bridge program, contains
definitions for all data elements (excluding FILLER) in messages. Both elemental and
group data items are in the dictionary so you can use them in DDE Request and DDE
Poke functions.
A group item that includes elements that are not alphanumeric will likely contain
special characters that have meaning to the Gateway when the CF_TEXT format is
being used. The special characters are binary zeros (decimal 0), carriage return
(decimal 13), and line feed (decimal 10).
If the group data item contains special characters, you can use DDE Poke and DDE
Request with the TdmgwBinaryElement registered clipboard format. For detailed
information, see the DDE Poke and DDE Request descriptions in the “DDE Functions”
topic earlier in this section.
Looping Through
Subscripted Tables
When using a series of DDE Poke or DDE Request functions for subscripted data
element names, cluster the DDE functions with the same element name to take best
advantage of Tandem DDE Gateway internal memory caches.
For example, do this:
REQUEST ("READ-REPLY.SALARY(1)")
REQUEST ("READ-REPLY.SALARY(2)")
REQUEST ("READ-REPLY.FIRST-NAME(1)")
REQUEST ("READ-REPLY.FIRST-NAME(2)")
rather than this:
REQUEST ("READ-REPLY.SALARY(1)")
REQUEST ("READ-REPLY.FIRST-NAME(1)")
REQUEST ("READ-REPLY.SALARY(2)")
REQUEST ("READ-REPLY.FIRST-NAME(2)")
If an application message has a large number of table rows, each with a number of
data elements, a large number of DDE Poke or DDE Request functions could be
required to transfer the message data between the Tandem DDE Gateway and storage
within your client application.
For example, a Tandem server for a hotel reservation system guest inquiry application
might have a reply message with a table of many guests with details for each guest. A