I have also encountered this problem and I think the OP may have solved it incorrectly. First, AddGeometryColumn is indeed overloaded. The three prototypes are:
AddGeometryColumn(table_name, column_name, srid, type, dimension,
use_typmod=true)
AddGeometryColumn(schema_name, table_name, column_name, srid, type, dimension, use_typmod=true)
AddGeometryColumn(catalog_name, schema_name, table_name, column_name, srid, type, dimension, use_typmod=true)
In my case, changing the following query:
SELECT AddGeometryColumn('public', 'facilities', 'walk_area', 4326, 'POLYGON', 2);
(which uses the second form) to this:
SELECT AddGeometryColumn('public', 'facilities', 'walk_area', 4326, 'POLYGON', 2, true);
solved the problem.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…