From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | samik(at)cae(dot)wisc(dot)edu (Samik Raychaudhuri) |
Cc: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: Problem in 'select' from temp table with Perl/DBI |
Date: | 2001-11-29 15:02:51 |
Message-ID: | 18414.1007046171@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
samik(at)cae(dot)wisc(dot)edu (Samik Raychaudhuri) writes:
> $query="select date_part('month', date) as month, date_part('year',
> date) as year into temp counter from weblogs;
> select month || '-' || year, count(*) from counter group by
> month, year;
> ";
> When I run this code, I get the following error message:
> DBD::Pg::st execute failed: ERROR: Relation 'counter' does not exist
> at counter.pl line 56.
You didn't say what postgres version you are using, but on older
versions I think it'd be necessary to issue those commands as two
separate statements. PG used to try to parse all the commands in
a querystring before executing any of them.
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Antonio Fiol Bonnín | 2001-11-29 16:06:50 | Re: time calculation |
Previous Message | Marek Pętlicki | 2001-11-29 13:29:56 | Re: Installing Libraries on remote pc |