"David Witham" <[EMAIL PROTECTED]> writes:
> So I see that there is the extra sort above the sub-query that
> wouldn't be there using 7.4. Are you saying that the sort by survey
> after the sort by survey,question would potentially reorder the
> records initially sorted by survey,question?
Exactly
ese rows even though they don't need to
be?
Regards,
David
-Original Message-
From: Tom Lane [mailto:[EMAIL PROTECTED]
Sent: Tuesday, 23 March 2004 16:17
To: David Witham
Cc: [EMAIL PROTECTED]
Subject: Re: [SQL] Sorting an aggregated column
"David Witham" <[EMAIL PROTECTED]
"David Witham" <[EMAIL PROTECTED]> writes:
> This output is correct in this case but there is no guarantee that the
> answers will come out in "question" order. I can't see how to
> incorporate sorting by the "question" column using this approach.
As of PG 7.4 you can reliably use a sorted sub-sel
Hi all,
I ran these commands:
create temp table dw_survey(survey int,question int,answer_bool boolean,answer_int
int,answer_char varchar);
insert into dw_survey values(1,1,'t',null,null);
insert into dw_survey values(1,2,'f',null,null);
insert into dw_survey values(1,3,'t',null,null);
insert int