[postgis-users] database wide unique ID

mlinden at zeelandnet.nl mlinden at zeelandnet.nl
Mon Jul 23 07:50:19 PDT 2007


Thank you Stephen for the best tip and Guido for supporting the discussion!

When I read Guido's answer I allready decided not to go with it. PostGres
user documentation describes that the OID's are only table wide unique and
even then you have to put the right constraints on them..

So, Stephen, I will try the solution and Guido; I am affraid to much
business processes are running on the nasty MSSQL machine(s) to kill it
;-) But a agree with you on the matter!

kind regards,

Milo van der Linden
> Stephen,
>
> OK. I guess this is a good solution. I just thought OIDs as I
> had some recent problems getting Postgis data displayed in
> QGIS and PGAdmin (clients). If you don't have a primary key,
> it tries to use OIDs for unique identifier. So you can tackle
> 2 problems in one go.
>
> GL
>
> Stephen Frost wrote:
>> * Guido Lemoine (guido.lemoine at jrc.it) wrote:
>>
>>> Use postgresql OIDs. These are "unique" object IDs.
>>>
>>
>> Do *not* use postgresql OIDs.
>>
>> Create a sequence and add a column to each table which defaults to
>> nextval() on that sequence.  He's only talking about 3 tables anyway.
>>
>> 	Thanks,
>>
>> 		Stephen
>>
>> ------------------------------------------------------------------------
>>
>> _______________________________________________
>> postgis-users mailing list
>> postgis-users at postgis.refractions.net
>> http://postgis.refractions.net/mailman/listinfo/postgis-users
>>
>
> --
> ----------------------------------------------------------------
> Guido Lemoine
> Joint Research Centre, European Commission
> Institute for the Protection and Security of the Citizen (IPSC)
> Unit: Support to External Security
> Via E. Fermi, 1 TP 267 Ispra 21020 (VA), Italy
> Tel. +39 0332 786239 (direct line) Fax. +39 0332 785154
> WWW: http://ses.jrc.it
> ----------------------------------------------------------------
> Disclaimer:
> Views expressed are those of the individual and do not represent
> the views of the European Commission
>
>
> _______________________________________________
> postgis-users mailing list
> postgis-users at postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users
>


Milo van der Linden

<a href="http://somafm.com/"><img
src="http://somafm.com/linktous/450x25sfm1.gif" alt="SomaFM" border=0
width=450 height=25 ></a>





More information about the postgis-users mailing list