ade_errstatement

AutoCAD Map 3D AutoLISP

Up a level
ade_errstatement
 
 

Gets the faulty SQL statement for a given error in the stack .

(ade_errstatement err_index)

Returns the faulty SQL statement with error position or nil.

err_index Position of the error in the stack (integer)
0 = first error

The SQL statement and error position are returned in the following format.

(faulty_statement err_pos)

The faulty_statement string quotes the faulty SQL statement that caused the error. The err_pos value identifies the starting position of the error in the faulty statement. Position 1 is the first character of the statement.

The expression (ade_errstatement 2), which references the third error in the stack, could return

("xxx" 6)

where "xxx" is the faulty statement and 6 tells you that the trouble begins at the sixth character.