steve.ebersole
unread,Jul 12, 2010, 12:07:50 PM7/12/10Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Sign in to report message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to H2 Database
I have the following query:
select vehicle0_.id as id
from (
select id, vin, owner, 3 as clazz_ from SUV
union all
select id, vin, owner, 4 as clazz_ from Pickup
union all
select id, vin, owner, 1 as clazz_ from Car
union all
select id, vin, owner, 2 as clazz_ from Truck
) vehicle0_
where owner is null
Which returns no hits, even though each table has 1 row each with a
null owner. Querying the individual tables for a null owner returns
correct counts; and querying the UNION returns 4 rows each with a NULL
value for owner.
Does anybody have any idea what is going on there?