Re: All columns from table in a joined query - Mailing list pgsql-sql

From Tom Lane
Subject Re: All columns from table in a joined query
Date
Msg-id 24653.1156368417@sss.pgh.pa.us
Whole thread Raw
In response to All columns from table in a joined query  (MHahn@seeandswim.com)
List pgsql-sql
MHahn@seeandswim.com writes:
> I've been trying to figure out how to do the following:
> Select schedule.* from schedule join meetingday on schedule.id = meetingday.scheduleid where sessionnumber = 165
groupby schedule.* order by min(meetingday.date);
 

I think what you're after is

select * from schedule where sessionnumber = 165
order by (select min(meetingday.date) from meetingday         where schedule.id = meetingday.scheduleid);
        regards, tom lane


pgsql-sql by date:

Previous
From: "Jim Buttafuoco"
Date:
Subject: Re: Deleting Functions
Next
From: Tom Lane
Date:
Subject: Re: Deleting Functions