Joseph,

> Actually I do it all the time, in the select part.

Hmm.  Frankly, I didn't know that Subselects in the field list were
supported, so this is a new one on me.


> Well that is the problem.  In my subselect I only want the latest
> value of ml.field, which 
> I get my ordering my ml.keyfield.  I don't see how group by could
> help.  I would need to 
> do something like: ... WHERE mll.keyfield = (select ml.keyfield from
> mltable ml where ... 
> order by ml.keyfield desc limit 1) which would be a subselect again
> which is what I'm 
> trying to avoid.
> 
> SQL is really annoying.

If you think SQL is annoying, you should try relational calculus  ;-)

Think you can provide me a simplified version of your table structure
and the results you're trying to get out of your query?  I think that
your problem is solvable with a little nested subselect, but I'm having
a lot of difficulty picturing what we're looking at.

-Josh


______AGLIO DATABASE SOLUTIONS___________________________
                                       Josh Berkus
  Complete information technology      [EMAIL PROTECTED]
   and data management solutions       (415) 565-7293
  for law firms, small businesses        fax 621-2533
    and non-profit organizations.      San Francisco

---------------------------(end of broadcast)---------------------------
TIP 2: you can get off all lists at once with the unregister command
    (send "unregister YourEmailAddressHere" to [EMAIL PROTECTED])

Reply via email to