Guardian Programmer's Guide

Table Of Contents
Writing a Requester Program
Guardian Programmer’s Guide 421922-014
21 - 20
Coding the Requester Program
!Data structure send to $SER3 to request information about a
!specified order:
STRUCT .ORDER^QUERY;
BEGIN
STRING ORDER^NUMBER[0:27];
END;
!Message returned by $SER1. It contains a part record:
STRUCT .PART^REC;
BEGIN
STRING PART^NUMBER[0:9]; !10-digit part number
STRING PART^DESC[0:47]; !part description
STRING SUPPLIER[0:23]; !name of part supplier
INT QUANTITY^ON^HAND; !quantity of parts on hand
INT UNIT^PRICE; !price of part
INT ORDER^PLACED[0:2];!date order placed with supplier
INT SHIPMENT^DUE[0:2];!date order due from supplier
INT QUANTITY^ORDERED; !quantity of part on order from
END; ! supplier
!Message returned by $SER2. After processing
!an order request, $SER2 returns this data structure
!containing the stock balance of the item ordered,
!and the order number:
STRUCT .ORDER^REPLY;
BEGIN
INT QUANTITY^ON^HAND; !quantity after order satisfied
STRING ORDER^NUMBER[0:27];!28-digit order number
END;