problem with oracle dbexpoda using the UNION SQL command.

problem with oracle dbexpoda using the UNION SQL command.

Postby clebernardelli » Mon 08 Jun 2009 13:56

I have problem with access to Oracle dbexpoda using the UNION command in SQL.

My table:

CREATE TABLE TEST
(A NUMBER (4),
B NUMBER (8),
C NUMBER (15));

When i SELECT * FROM TEST the list of fields that returns is:
A TSmallIntField
B TIntegerField
C TFLOATFIELD

But when i do SELECT * FROM TEST UNION SELECT * FROM TEST the list of fields that returns is:
A TFLOATFIELD
B TFLOATFIELD
C TFLOATFIELD

The driver version is: 2.10 the delphi version is 7 Enterprise and Oracle version is 9.2 (but tested on version 10g and also happens).

The parameters using in driver is:
EnableBCD=False
IntegerPrecision=9
SmallintPrecision=4
FloatPrecision=38

Someone help me please?
clebernardelli
 
Posts: 1
Joined: Mon 08 Jun 2009 13:33

Postby Plash » Tue 09 Jun 2009 07:53

Oracle does not return the precision of fields when you are using UNION. So you should work with different field lists for these two queries.
Plash
Devart Team
 
Posts: 2844
Joined: Wed 10 May 2006 07:09


Return to dbExpress driver for Oracle