[postgis-users] shp2pgsql importing WITH OIDS
Paul Ramsey
pramsey at refractions.net
Tue Dec 4 09:31:20 PST 2007
At this point I would be more interested in changing the behavior of
SIS than changing the behavior of PostGIS. OIDs are deprecated so we
should not be moving to *improve* our support of them at this late
date. SIS can follow the lead of Mapserver, and uDig and look for a
defined primary key in the PgSQL system tables instead of the OID,
and disable editing for layers that do not have a primary key.
(And BTW, mea culpa for ever using them in a client application in
the first place, I'm sure even back in 2001 the PgSQL developers
would have warned against doing so. By using them in Mapserver way
back then we set a terrible precedent for all the application
developers that came afterwards and templated on that development
pattern.)
Paul
On 4-Dec-07, at 8:03 AM, Steve Grey wrote:
> Hi all,
>
> I know there have been postings before on the subject, but I could
> really really do with a command line switch in shp2pgsql, such as -o.
>
> I have no option but to use oids - I'm loading so Cadcorp GIS can
> read the layers, but they need to be a) in the geometry_columns
> table and b) defined WITH OIDS to be visible.
>
> At present I'm loading without OIDS, recreating the table with
> another name, copying across and recreating indexes etc. - in other
> words doing twice the work.
>
> Whilst I do appreciate OIDS are deprecated, PostgreSQL allows to
> backup and restore with oids and tables can still be created WITH
> OIDS or the default setting changed - and checking during a restore
> all that happens is WITH OIDS is put into a copy statement when
> restoring from a .backup file.
>
> Your thoughts please!
>
> Thanks,
>
> Steve
> _______________________________________________
> 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