On Fri, 21 May 2010 05:14:17 -0700 (PDT),
mozo...@hotmail.fr wrote
> the "geometry column doesn't statisfie required constraint" seems to
> be because i still got data in the table. I've create a test table
> with just an ID and a POINT column but i can't insert any data
> (constraint failed) since the index is created.
>
please, check the following example:
CREATE TABLE test_table (
ID INTEGER PRIMARY KEY NOT NULL);
SELECT AddGeometryColumn('test_table',
'Geometry', 4326, 'POINT', 'XY');
SELECT CreateSpatialIndex('test_table',
'Geometry');
INSERT INTO test_table (ID, Geometry)
VALUES(1, GeomFromText('POINT(1 1)', 4326));
INSERT INTO test_table (ID, Geometry)
VALUES(2, GeomFromText('POINT(2 2)', 4326));
INSERT INTO test_table (ID, Geometry)
VALUES(3, GeomFromText('POINT(3 3)', 4326));
SELECT ID, AsText(Geometry) FROM test_table;
bye Sandro