Re: Help needed: Retrieve only rows where numbers are concurrent
From: David Cressey <david_at_dcressey.com>
Date: Sun, 14 Jul 2002 22:30:43 GMT
Message-ID: <nYmY8.20$Jd4.2324_at_petpeeve.ziplink.net>
Date: Sun, 14 Jul 2002 22:30:43 GMT
Message-ID: <nYmY8.20$Jd4.2324_at_petpeeve.ziplink.net>
Steve,
> I'm not entirely sure what you want. I guessed that "concurrent"
> meant consecutive, so you want slot_id values of N, N+1 and N+2.
> If that's what you want, David's query won't assure that - it will find
> trainer_id, room_id pairs with three different slot_id values.
>
You are right. I never would have guessed that "concurrent" meant "consecutive".
My solution also depends on the absence of duplicate rows in the input tables. I unconsciously assumed that as given. It's my tendency to think of tables as if they always represent relations...on good days, they usually do.
-- Regards, David CresseyReceived on Mon Jul 15 2002 - 00:30:43 CEST