You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
PostgreSQL driver doesnt read Z and M Geometry suffixes from coord_dimension #12747
When loading tables form DB and using PostGIS, PostgreSQL driver doesnt take into account coord_dimension column of geometry_columns table. Therefore when using specific geometry spatialFeatureType like GeometryZ TypeORM generates migration to this type over and over again.
Expected Behavior
Translate coord_dimension and type columns of geometry columns table into correct spatialFeatureType
ie
coord_dimension
type
spatialFeatureType
2
GEOMETRY
Geometry
3
GEOMETRY
GeometryZ
3
GEOMETRYM
GeometryM
4
GEOMETRY
GeometryZM
Actual Behavior
Only type field is taken into account, so if I create a table with GeometryZ column, generate migration and apply it, all following generated migrations will still have this change included, despite columns being already GeometryZ:
publicasyncup(queryRunner: QueryRunner): Promise<void>{awaitqueryRunner.query(`ALTER TABLE "test" ALTER COLUMN "geometry" TYPE geometry(geometryz,5514)`);}publicasyncdown(queryRunner: QueryRunner): Promise<void>{awaitqueryRunner.query(`ALTER TABLE "test" ALTER COLUMN "geometry" TYPE geometry(GEOMETRY,5514)`);}
changed the title [-]PostgreSQL driver doesnt read coord_dimension[/-][+]PostgreSQL driver doesnt read Z and M suffixes from coord_dimension[/+]on Jul 31, 2026
changed the title [-]PostgreSQL driver doesnt read Z and M suffixes from coord_dimension[/-][+]PostgreSQL driver doesnt read Z and M Geometry suffixes from coord_dimension[/+]on Jul 31, 2026
Activity
[-]PostgreSQL driver doesnt read coord_dimension[/-][+]PostgreSQL driver doesnt read Z and M suffixes from coord_dimension[/+][-]PostgreSQL driver doesnt read Z and M suffixes from coord_dimension[/-][+]PostgreSQL driver doesnt read Z and M Geometry suffixes from coord_dimension[/+]fix(postgres): read coord_dimension when loading spatial columns
fix(postgres): read coord_dimension when loading spatial columns