Subject Re: [IBO] statement Union in a TIBO_Query
Author Helen Borrie
At 06:27 PM 27/08/2004 +0200, you wrote:
>I'm using a TIBO_Query to run the following SQL statement
>
>SELECT CODE,NAME FROM CLIENTS
>
>UNION
>
>SELECT CODE,NAME FROM OPERATORS
>
>and I'm getting the following Error Message:
>
>----------------------------------------------------------------------------
>---
>ISC ERROR CODE: 335544569
>ISC ERROR MESSAGE:
>Dynamic SQL error code = -104
>Invalid Command
>Data Type Unkown
>
>STATEMENT:
>TIBOInternalDataset: "DataModuleForm.DModule.QrSearch.
><TIBOInternalDataSet>."
>----------------------------------------------------------------------------
>----
>
>The same statement works fine in a TQuery, does TIBO_Query support the UNION
>statement or I'm doing something wrong?

The exception is coming from the db engine, not from IBO, i.e. the DB
engine doesn't like your query syntax.

Questions (for testing purposes):

1. Which DB engine are you using?
2. Are you using TIB_Query or TIBOQuery?
3. What is the metadata of the two columns in each table, respectively?
4. What statement are you seeing in the SQL monitor?
5. What version of IBO?

Helen
>