[postgis-devel] Unknown SRID value: 0 or -1 ?
Sandro Santilli
strk at keybit.net
Mon Dec 12 08:20:47 PST 2011
On Fri, Dec 09, 2011 at 04:15:40PM -0500, Paragon Corporation wrote:
> > I've started work on testing dump/restore procedure for getting to 2.0
> > and realized the data w/out a proper SRID won't come back due to
> > ensure_srid_geom checks on tables insisting of the SRID being -1
> > rather than 0.
>
> > There's no much we can do to fix this, unless we're willing to
> > drop the constraints from the user dump.
>
> > For this reason I think it would be safer to get our unknown
> > srid back to -1 before it's too late (srid=0 getting in dumps
> > and making things even harder).
>
>
> My proposition -- change to srid = 0 as our official.
> For existing we create a prepare_for_postgis20.sql
>
> That people run on their existing database that does this:
>
> 1) Fixes existing constraints -- not its not just -1 srid. There is the
> ndims one needs to be changed to st_ndims.
>
> 2) Some old ones use srid function.
>
> 3) For unknown srid checks -- the script will just remove them.
>
> 4) For people using the French SRID that is larger than our max srid, we
> have the script
> change the srid to something that fits in our current srid limit.
>
> Jus thave to decide what SRID to move
Sounds good to me.
Should such script know the provenience or only destination ?
I filed a ticket about finding a clear upgrade path:
http://trac.osgeo.org/postgis/ticket/1367
Such a "preparator" script should be part of that path.
--strk;
,------o-.
| __/ | Thank you for PostGIS-2.0 Topology !
| / 2.0 | http://www.pledgebank.com/postgistopology
`-o------'
More information about the postgis-devel
mailing list