Example 1: Remote non-persistent procedure example
- Last Updated: January 27, 2016
- 1 minute read
- OpenEdge
- Version 13.0
- Documentation
This example shows how to run a remote, non-persistent procedure, checkstk.p, on a PAS for OpenEdge instance identified as hAppSrv. The TRANSACTION
DISTINCT option is used on the RUN
statement to specify that the client application's transaction is not propagated to
hAppSrv. The two temp-table parameters that are
defined, ttOrderLine and ttItem, are passed as INPUT and OUTPUT parameters, respectively, to the checkstk.p procedure, as shown:
|
When the RUN statement is executed, a remote
procedure request to run checkstk.p is sent to the
PAS for OpenEdge instance that is connected via the hAppSrv
server handle. Once the RUN statement is completed,
this code checks to see if checkstk.p completed
with an ERROR condition as would occur by executing the
RETURN ERROR statement. If checkstk.p did execute the RETURN
ERROR statement, then this code also returns with an ERROR condition. By using the RETURN-VALUE function, the code also returns the value returned by
checkstk.p.