Subject Re: [IBO] TIB_Query: Problem with SQL Parsing?
Author Helen Borrie
At 04:30 PM 8/09/2003 +0000, you wrote:
>Hello,
>
>I have a TIB_Query component with a very simple SQL statement
>assigned at design time to SQL property:
>
>----------------
>SELECT
> *
>FROM
> DEALS
>----------------
>
>However, it gives me the following error when trying to open the
>query:
>----------------
>ISC ERROR CODE:335544569
>
>ISC ERROR MESSAGE:
>Dynamic SQL Error
>SQL error code = -104
>Token unknown - line 4, char 6
>,
>----------------
>
>When I programmatically removed CR and LF characters (#13#10) from
>SQL.Text before opening a query, all worked fine.
>
>What is wrong here?

How did the CR and LF characters get in there? How are you setting the SQL
property?


>On a separate note, BeforeOpen event (where I tried to put that
>patch code) didn't fire at all before opening TIB_Query. Why?

What do you mean by "patch code". Do you understand that, if you get an
exception during Prepare, the BeforeOpen event never fires?

More info >>> better help.

Helen