[GIS] Error import shapeFile shp2pgsql-gui

importpostgisshapefile

I'm trying to import a shapefile to my PostGIS database but I can not, give a look:

Importing with configuration: 12mie250gc_sir, public, geom, / home/samuelribeiro/Desktop/MALHA_DIGITAL/ac/12MIE250GC_SIR, mode = c, dump = 1, simple = 0, geography = 0, index = 1, shape = 1, srid = 4326
Shapefile type: PolygonM
PostGIS type: MULTIPOLYGONM [3]
Failed SQL begins: "SET TO UTF8 CLIENT_ENCODING;
STANDARD_CONFORMING_STRINGS SET TO ON;
BEGIN;
CREATE TABLE "public". "12mie250gc_sir" (gid serial,
"id" float8
"nm_micro" varchar (100),
"cd_geocodu" varchar (2));
ALTER TABLE "public". "12mie250gc_sir" ADD PRIMARY KEY (gid);
SE "
Failed in pgui_exec (): ERROR: function AddGeometryColumn (unknown, unknown, unknown, unknown, unknown, integer) is not unique
LINE 9: SELECT AddGeometryColumn ('public', '12mie250gc_sir ',' geom ', '4 ...
                ^
HINT: Could not choose a best candidate function. You might need to add explicit type casts.

Shapefile import failed.

Best Answer

Looks like you're loading into a database that either (a) has a version of PostGIS installed that doesn't match the loader or (b) has no PostGIS installed at all. Run "select postgis_full_version()" in your target database and see if it's the version you expect.