On Dec 4, 2007 1:01 PM, Marco Mariani <[EMAIL PROTECTED]> wrote:
> > I don't care how many columns are returned, but I want to tell it
> > which ones should be distinct,  and still get the benefits of the
> > mapping.
> >
>
> What do you mean "which ones should be distinct" ?
>
> I mean,  distinct is not a function (*)
>
> What's your use case?

Oops. I should know better than to write while medicated. ;-)  Sorry.
That didn't make much sense.  Ignore that.

In the simplest case, which I can get around other ways, I have data
for different U.S. states.  In a few situations, I have more than one
row with the state name and abbreviations.  I only want a unique list
of state names, abbreviations, and ranks.  No duplicates.  So, I want

Since I'm trying to wrap my head around things with a "TurboGears in
20-minutes" attitude, I'm trying to work with relatively simple stuff.
So, using Elixir, I want the best way to do something like:

SELECT DISTINCT rank, usps, name FROM states WHERE rank < 60 ORDER BY rank;

and have everything fit nicely into the model class States without me
reinventing the wheel.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TurboGears" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/turbogears?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to