[postgis-users] PostGIS view in qgis
Eduin Yezid Carrillo Vega
yecarrillo at gmail.com
Mon Mar 9 04:40:33 PDT 2009
If your postgresql version is 8.0 or less you can use OID fields as
key identifier.
CREATE VIEW myview AS SELECT oid AS gid, the_geom FROM mytable;
In postgresql 8.3 you can force oid creation if WITH OIDS is specified
when the table is created
Eduin Yesid Carrillo Vega
Ingeniero Civil, Esp. Sistemas de Información Geográfica
Centro de Investigación y Desarrollo en Información Geográfica
Instituto Geográfico Agustín Codazzi - IGAC
Cr 30 48-51
Tel +57 1 3694000 ext 4593
Bogotá D.C., Colombia
On Mon, Mar 9, 2009 at 2:43 AM, Marc Jansen <jansen.marc at gmx.de> wrote:
> HI Martin,
>
>
> Martin Fafard schrieb:
>>
>> Hi
>>
>> I polygonize linestrings in a view to see the result in qgis. But qgis
>> need gid. How can I create the gid column after an aggregate function in a
>> view?
>
> AFAIK you can't. Maybe a table (created by your query) with a serial /
> primary key helps.
>
> --Marc
>
>
>
>>
>> Martin F
>> _______________________________________________
>> postgis-users mailing list
>> postgis-users at postgis.refractions.net
>> http://postgis.refractions.net/mailman/listinfo/postgis-users
>>
>
> _______________________________________________
> postgis-users mailing list
> postgis-users at postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users
>
More information about the postgis-users
mailing list