PowerExchange for CDC and Mainframe
- PowerExchange for CDC and Mainframe 10.5.4
- All Products
Parameter
| Datatype
| Use
| Description
|
---|---|---|---|
NbrFlds
| Integer
| Input
| Specifies the number of arguments passed to the CallProg function. For example, if you pass the following two arguments to the CallProg function:
PowerExchange sets the NbrFlds parameter to 2.
Internally, arguments are passed to the CallProg function through the ppData and ppDataLen arrays. The use of the NbrFlds integer and the ppData and ppDataLen arrays by PowerExchange is similar to the use of the argc integer and the argv array in a C program:
|
pDataLen
| Array of pointers
| Input and output
| Specifies the lengths of the arguments passed to the CallProg function.
The length of an argument is determined by its datatype, as follows:
When fields are returned to the CallProg function, you must reset the data length if it has changed.
For example, to change the data and length of second argument with a datatype of VARCHAR, you might code the following statements:
|
pMsgBuffer
| Pointer to a character string
| Output
| Points to a message buffer into which the user-defined program can return a NULL-terminated message string that describes an error. PowerExchange issues the returned message if the user-defined program returns a non-zero return code. If no error occurs, Informatica recommends that the user-defined program leave the message buffer empty.
When returning error messages, do not exceed the memory buffer size allocated by the CallProg routine, which is 128 bytes.
|
pMsgBufferSize
| Integer pointer
| Input and output
| Specifies the message buffer size. If an error occurs, the user-defined program can return an error message that includes the message buffer size by using the following syntax:
Return the size of the message buffer if the returned message string is not NULL-terminated.
|
ppData
| Array of pointers
| Input and output
| An array of pointers to the data for the arguments passed to the CallProg function.
This data is accessed in the same way that data is accessed in the argv array on the C main function. For example, to get the data from the second field of field of type STRING, you might code the following statements:
|