DBerrorString
Synopsis
DBerrorString inserts a marker into an input string at a specified position.
Input Ports
Parameters
Output Ports
Description
DBerrorString inserts a marker into an input string at a specified position and returns the resulting string. The marker is the string ----->>.
This module is useful for creating an output string showing where an error occurred in an invalid SQL statement. To do this, you must enter the invalid SQL statement and the error offset from the beginning of the statement into the statement and error_offset input ports, respectively. (The error offset is returned by the database server.) The value returned in the valid_error output port indicates when DBerrorString has finished processing; you can use this as a trigger to open a UIwindow in which error information, including the output string, is displayed. For an example, see The Toolkits Book.
Input
The offset (in bytes) from the beginning of the string indicating where the marker will be inserted. Typically, this is the error offset returned by the database server to indicate the position within an invalid SQL statement where an error occurred.
A trigger that initiates execution of the string insert operation. When this value changes to a value greater than 0, the operation is executed.
Parameters
Output Port
A string that consists of the input statement with the marker inserted at the position indicated by error_offset.
A return value that indicates the processing status of the string insert operation. A value of 1 indicates that the string insert is being processed; a value of 0 indicates that processing has completed.
Example
File
See also related modules