Fix postgis dialect undefined srid for PostGIS 2.x

Ensures compatibillity with PostGIS 1.x and 2.0