Note: Built-In Function Rules Usage Options
Calls (executes) a LANSA application on the nominated server and waits until it completes execution. The function must be a *DIRECT function.
Arguments
|
Return Values
|
Technical Notes
Portability Considerations |
Servers defined with DEFINE_OS_400_SERVER: The aggregate byte length of a working list passed to a server cannot exceed 32,000 bytes. The aggregate byte length is the entry byte length multiplied by the current number of entries. As 1 to 10 working lists can be passed to the function on the server, the total number of bytes that can be passed to the Server is 320,000, that is, 10 working lists of 32,000 bytes each. This Built-In Function will cause a fatal error message if a client function passes a list that is too large. However, the server function is a different matter. The working list it receives as a parameter is in memory allocated by its caller (i.e. the IBM i based server controller). If it attempts to add too many entries to the working list it may "zap" the server controller and cause an application failure. If an unexpected failure of CALL_SERVER_FUNCTION occurs, and working lists are involved, then look to this point as the first possible cause ..... the server function may be overfilling the working list(s). |
A Note on Error Handling
It is very strongly recommended that you avoid building complex error handling schemes into your applications. Use a very simple trap like this at all levels of your application.
if (#retcode *ne OK)
abort msgtxt('Failed to .............................')
endif
Let the standard error handling Built-In Function to every generated application take care of the problem. Situations have arisen where user defined error handling logic has become so complex as to consume 40 - 50% of all RDML code (with no obvious benefit to the application). Do not fall into this trap.