All I can say is "Huh, that's funny." It looks like perfectly
good SQL to me. You've tried this command at an SQL prompt?
What about trimming it down, only querying on that table,
for example.
Anyway, in general, you don't have to select a column to use
it in the where clause.
Good luck,
Scott
Comment on Re: generated SQL statement problem (OT)