Re: Bug, feature, quirk? HELP - Mailing list pgsql-general

From Len Morgan
Subject Re: Bug, feature, quirk? HELP
Date
Msg-id 002501c0c5b1$ff37bca0$0908a8c0@H233.bstx.cc
Whole thread Raw
In response to Bug, feature, quirk? HELP  ("Stoppel, Brett W" <bstoppel@ku.edu>)
List pgsql-general
>I tried the following command
>
>db=> SELECT DISTINCT name, city FROM table ORDER BY trim(table.name);
>ERROR:  For SELECT DISTINCT, ORDER BY expressions must appear in target
list

Try:

SELECT DISTINCT trim(name) AS name,city FROM table ORDER BY name ;

And if that doesn't work:

SELECT DISTINCT trim(name),city FROM table ORDER BY trim(name) ;



pgsql-general by date:

Previous
From: "Stoppel, Brett W"
Date:
Subject: Bug, feature, quirk? HELP
Next
From: Tom Lane
Date:
Subject: Re: Bug, feature, quirk? HELP