From: | "ktm(at)rice(dot)edu" <ktm(at)rice(dot)edu> |
---|---|
To: | "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com> |
Cc: | Jason Aleski <jason(dot)aleski(at)gmail(dot)com>, "pgsql-sql(at)postgresql(dot)org" <pgsql-sql(at)postgresql(dot)org> |
Subject: | Re: ERROR: column "gid" specified more than once |
Date: | 2015-05-12 15:53:09 |
Message-ID: | 20150512155309.GH31129@aart.rice.edu |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-sql |
On Tue, May 12, 2015 at 08:49:53AM -0700, David G. Johnston wrote:
> On Tuesday, May 12, 2015, Jason Aleski <jason(dot)aleski(at)gmail(dot)com> wrote:
>
> > You probably need to specify your wildcard on both tables.
> >
> > CREATE TABLE "BorujerdDistCent" as
> > SELECT
> > "Borujerd".*, "Lorestan".*,
> > t_distance(st_centroid("Lorestan".geometry),"Borujerd".geometry)/1000
> > as DistFromCntroid
> > FROM "Borujerd", "Lorestan"
> >
> >
> My bad on the assumed -bugs list from before...
>
> Anyway, how is this suugestion different from simply saying "*" without a
> relation specification - which the OP did and it didn't work.
>
> David J.
Because the column names are differentiated by their prefixes then:
Borujerd.gid, Lorestan.gid
No conflict.
Regards,
Ken
From | Date | Subject | |
---|---|---|---|
Next Message | David G. Johnston | 2015-05-12 16:09:33 | Re: ERROR: column "gid" specified more than once |
Previous Message | David G. Johnston | 2015-05-12 15:49:53 | Re: ERROR: column "gid" specified more than once |