Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Problem with NULL columns in UNION's
we are doing selects from two different tables using a UNION. If there
is no corresponding
column on the second table we have been using NULL in SQL Server.
Unfortunately ORACLE rejects
this on numeric & date columns giving error (ORA-01790 expression must
have same
datatype as corresponding expression).
The only solution to this I have found so far is to use TO_NUMBER(NULL)
and
TO_DATE(NULL,'DDMMYY'). is this the best resolution ?
Received on Wed Aug 18 1999 - 08:56:09 CDT