Re: NULL, OR, and indexes

2005-12-12 Thread Eamon Daly
on Daly" <[EMAIL PROTECTED]> Cc: Sent: Monday, December 12, 2005 2:45 PM Subject: Re: NULL, OR, and indexes In the last episode (Dec 12), Dan Nelson said: In the last episode (Dec 12), Eamon Daly said: > I'm sure the answer is "You're SOL", but I figured I'd

Re: NULL, OR, and indexes

2005-12-12 Thread Dan Nelson
In the last episode (Dec 12), Dan Nelson said: > In the last episode (Dec 12), Eamon Daly said: > > I'm sure the answer is "You're SOL", but I figured I'd ask anyway. I > > have a WHERE condition like: > > > > SELECT * FROM a JOIN b WHERE > > (b1 IS NULL OR b1 = u1) AND > > (b2 IS NULL OR b2 = u2)

Re: NULL, OR, and indexes

2005-12-12 Thread Dan Nelson
In the last episode (Dec 12), Eamon Daly said: > I'm sure the answer is "You're SOL", but I figured I'd ask anyway. I > have a WHERE condition like: > > SELECT * FROM a JOIN b WHERE > (b1 IS NULL OR b1 = u1) AND > (b2 IS NULL OR b2 = u2) AND > (b3 IS NULL OR b3 = u3) > > where b is a Very Large t

NULL, OR, and indexes

2005-12-12 Thread Eamon Daly
I'm sure the answer is "You're SOL", but I figured I'd ask anyway. I have a WHERE condition like: SELECT * FROM a JOIN b WHERE (b1 IS NULL OR b1 = u1) AND (b2 IS NULL OR b2 = u2) AND (b3 IS NULL OR b3 = u3) where b is a Very Large table. I have an index on b like (b1, b2, b3), but obviously that