Sorry Steve sir. But I tried the DROP CONSTRAINT command like you wrote. But its not working. I got the same error.
VSDelhidb=# SELECT assign_vertex_id(‘roads_line’, 0.0002, ‘the_geom’, ‘gid’);
NOTICE: CREATE TABLE will create implicit sequence “vertices_tmp_id_seq” for serial column “vertices_tmp.id”
CONTEXT: SQL statement “CREATE TABLE vertices_tmp (id serial)”
PL/pgSQL function “assign_vertex_id” line 15 at EXECUTE statement
ERROR: new row for relation “vertices_tmp” violates check constraint “enforce_srid_the_geom”
CONTEXT: SQL statement “INSERT INTO vertices_tmp(the_geom) VALUES (SetSRID(p,_srid))”
PL/pgSQL function “point_to_id” line 26 at SQL statement
PL/pgSQL function “assign_vertex_id” line 33 at assignment
It says new row for relation “vertices_tmp” violates check constraint. Could it be that this constraint is derived or inherited from somewhere?
What happens if you say
select count(*) from xxxx_Table where the_geom is null;
where xxxx_Table is the name of the table and the_geom is the name of your
geomtry column ?
This statement should return the number of null columns, it should be zero.
Annu Anurag wrote:
Sorry Steve sir. But I tried the DROP CONSTRAINT command like you wrote.
But its not working. I got the same error.
VSDelhidb=# SELECT assign_vertex_id('roads_line', 0.0002, 'the_geom',
'gid');
NOTICE: CREATE TABLE will create implicit sequence "vertices_tmp_id_seq"
for serial column "vertices_tmp.id"
CONTEXT: SQL statement "CREATE TABLE vertices_tmp (id serial)"
PL/pgSQL function "assign_vertex_id" line 15 at EXECUTE statement
ERROR: new row for relation "vertices_tmp" violates check constraint
"enforce_srid_the_geom"
CONTEXT: SQL statement "INSERT INTO vertices_tmp(the_geom) VALUES
(SetSRID(p,_srid))"
PL/pgSQL function "point_to_id" line 26 at SQL statement
PL/pgSQL function "assign_vertex_id" line 33 at assignment
It says new row for relation "vertices_tmp" violates check constraint.
Could it be that this constraint is derived or inherited from somewhere?
_______________________________________________
Pgrouting-users mailing list
Pgrouting-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/pgrouting-users
--
Hey,
It looks to me like you are either:
- Trying to put a type of Geometry into a column which doesn't expect
it. For example you've told it that the column will be made of points,
and infact you're trying to put lines into it.
- Trying to take data that is registered as having one SRID (e.g.
27700) and putting it into a column which you have said only accepts
another SRID (e.g. 4326)
Not quite sure of how to check this though.
James
On 12 June 2012 15:51, Dave Potts <dave.potts@pinan.co.uk> wrote:
What happens if you say
select count(*) from xxxx_Table where the_geom is null;
where xxxx_Table is the name of the table and the_geom is the name of your
geomtry column ?
This statement should return the number of null columns, it should be zero.
Annu Anurag wrote:
Sorry Steve sir. But I tried the DROP CONSTRAINT command like you wrote.
But its not working. I got the same error.
VSDelhidb=# SELECT assign_vertex_id('roads_line', 0.0002, 'the_geom',
'gid');
NOTICE: CREATE TABLE will create implicit sequence "vertices_tmp_id_seq"
for serial column "vertices_tmp.id"
CONTEXT: SQL statement "CREATE TABLE vertices_tmp (id serial)"
PL/pgSQL function "assign_vertex_id" line 15 at EXECUTE statement
ERROR: new row for relation "vertices_tmp" violates check constraint
"enforce_srid_the_geom"
CONTEXT: SQL statement "INSERT INTO vertices_tmp(the_geom) VALUES
(SetSRID(p,_srid))"
PL/pgSQL function "point_to_id" line 26 at SQL statement
PL/pgSQL function "assign_vertex_id" line 33 at assignment
It says new row for relation "vertices_tmp" violates check constraint.
Could it be that this constraint is derived or inherited from somewhere?
_______________________________________________
Pgrouting-users mailing list
Pgrouting-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/pgrouting-users
--
_______________________________________________
Pgrouting-users mailing list
Pgrouting-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/pgrouting-users