Subject RE: [IBO] TIB_DSQL - conversion error on a value not referenced?
Author Jason Wharton
This could be due to trigger initiated updates.
Look in the SQL trace monitor for more exact clues.

Jason Wharton

-----Original Message-----
From: ra8009 [mailto:ra8009@...]
Sent: Tuesday, August 24, 2004 9:26 PM
To: IBObjects@yahoogroups.com
Subject: [IBO] TIB_DSQL - conversion error on a value not referenced?


I have a program that's assigning a simple UPDATE statement to a the
SQL property of a TIB_DSQL instance at runtime. This operation is part
of a while loop and I call ExecSQL after the SQL is set. The SQL looks
like this:

UPDATE MYTABLE SET MYVAR20FLD = MYSTRING1 WHERE MYVAR20FLD = MYSTRING2

At the runtime the statment runs correctly a few times, then it errors
saying that "conversion error from string QW-34-8907".

Here's the problem. At the moment that the query runs the value of
MYSTRING2 is NOT QW-34-8907. The value QW-34-8907 exists in my table,
but is not in any way referenced in the currect SQL statement.

I've unsuccessfully tried:

1) clearing the parameters: DSQL1.Params.ClearBuffers(rsNone);
2) Using IB_DSQL2.ExecuteDML(Statement,nil);

What else could be causing this?