[gdal-dev] sqlite -> spatialite (rowid)

Even Rouault even.rouault at spatialys.com
Tue Mar 7 06:50:47 PST 2017


Arg, it seems my email has been truncated in text version. Retrying...

> Now I delete feature with rowid=3:
>

Let's see the state:

$ ogrinfo test.db -al
INFO: Open of `test.db'
      using driver `SQLite' successful.

Layer name: test
Geometry: Unknown (any)
Feature Count: 2
Extent: (1.000000, 2.000000) - (5.000000, 6.000000)
Layer SRS WKT:
(unknown)
FID Column = rowid
Geometry Column = GEOMETRY
OGRFeature(test):1
  POINT (1 2)

OGRFeature(test):5
  POINT (5 6)

 $ ogrinfo test.db -sql "select * from idx_test_GEOMETRY"
INFO: Open of `test.db'
      using driver `SQLite' successful.

Layer name: SELECT
Geometry: None
Feature Count: 2
Layer SRS WKT:
(unknown)
pkid: Integer (0.0)
xmin: Real (0.0)
xmax: Real (0.0)
ymin: Real (0.0)
ymax: Real (0.0)
OGRFeature(SELECT):0
  pkid (Integer) = 1
  xmin (Real) = 1
  xmax (Real) = 1
  ymin (Real) = 2
  ymax (Real) = 2

OGRFeature(SELECT):1
  pkid (Integer) = 5
  xmin (Real) = 5
  xmax (Real) = 5
  ymin (Real) = 6
  ymax (Real) = 6


-> The spatial index has been properly maintained: the entry corresponding to the deleted 
feature has been deleted as well.

Even

-- 
Spatialys - Geospatial professional services
http://www.spatialys.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20170307/aa1db6a3/attachment.html>


More information about the gdal-dev mailing list