From: | Bruce Momjian <maillist(at)candle(dot)pha(dot)pa(dot)us> |
---|---|
To: | sthomas(at)cise(dot)ufl(dot)edu (Shiby Thomas) |
Cc: | hackers(at)postgreSQL(dot)org (PostgreSQL-development) |
Subject: | Re: [HACKERS] group by problem |
Date: | 1998-02-20 19:29:08 |
Message-ID: | 199802201929.OAA07166@candle.pha.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
>
>
> => > insert into FTemp1 select item as item1, count(*) as cnt from data group by
> => > item;
> => > ERROR: The field being grouped by must appear in the target list
> => >
> => > Thanks
> => > --shiby
> =>
> => Say:
> =>
> => group by item1.
> It works.
> =>
> But, just wanted to check this also.
> I get the same error for:
> insert into FTemp1 select item, count(*) as cnt from data group by item
> also.
>
> So, is it mandatory now to give alias names for all the selected columns if
> we are using group by
No, I am sorry. Looks like we have a bug where GROUP BY can't be used
with INSERT ... SELECT.
--
Bruce Momjian
maillist(at)candle(dot)pha(dot)pa(dot)us
From | Date | Subject | |
---|---|---|---|
Next Message | geek+ | 1998-02-20 19:46:01 | Re: [HACKERS] Who is everyone? |
Previous Message | Bruce Momjian | 1998-02-20 19:27:08 | Re: [HACKERS] Backend crashes - what's going on here??? |