Guardian Programmer's Guide

Table Of Contents
Writing a Server Program
Guardian Programmer’s Guide 421922-014
22 - 10
The Part-Query Server ($SER1)
The requester chooses the server to send a request to depending on the function
requested by the user:
If the user requests to query a part record, then the requester obtains the part
record by sending a request to the part-query server ($SER1). The $SER1
process obtains the information from the inventory file and returns it to the
requester.
If the user requests to process an order, the requester sends a message to the
process-order server ($SER2). This server uses the information it receives to
update the inventory level in the inventory file and to create an order record and
put it in the orders file. The server returns the order number to the requester.
If the user wants to query an existing order record, then the requester sends a
message to the order-query server ($SER3), which queries the orders file and then
sends the corresponding order record back to the requester.
See Section 21, Writing a Requester Program, for a detailed description of the
requester process.
The Part-Query Server ($SER1)
Figure 22-3 shows the internal function of the part-query server, in terms of its major
procedures.
Figure 22-2. Server Processes in the Example Application
VST109.VSD