Database Vuser Functions (LRD) > Alphabetical List of Functions > lrd_save_value


Example: lrd_save_value Correlating Statements Functions

Saves the value of a placeholder descriptor.

LRDRET lrd_save_value( LRD_VAR_DESC *mptVarDesc, unsigned long muIiIndex, unsigned long muliOption, char *mpszParamName );

mptVarDesc A pointer to the descriptor of the variable to be saved.
muliIndex The index of the element to be saved (0 for scalars).
muliOption One of the Save Value Options.
mpszParamName A parameter name using alpha-numerical characters, enclosed by quotation marks.

The lrd_save_value function saves the dynamic value of a placeholder descriptor. This function is used for Correlating Database Statements that set output placeholders (such as certain stored procedures on Oracle). This dynamically saved value can be used by other database statements within the same script. Note that lrd_save_value always follows an lrd_exec statement.

In instances where table columns have constraints such as Unique, correlating your script's queries may be the only way to run the script. For example, if during recording, you inserted a value into a table with a Unique key constraint, you will be unable to insert the same value again. If you try to run the script as recorded, you will get a database error.

For more details refer to the Function Header File lrd.h in the include directory.

Return Values

See LRD Return Values.


You cannot use standard parameterization for any arguments in this function.