[GIS] Is the PostGIS Shapefile Import Manager able to upload to phptheadmin or only pgadmin III

importpgadmin-3PHPshapefilespatial-database

After trying to import a shapefile into pgadmin III with no success I was wondering how to successfully upload it, but also if it is possible to upload to phpmyadmin instead. In any case, how exactly do I change the encoding so that they are compatible in pgadmin. No matter what I don't want to change the shapefile as it was more likely my error in uploading and configuring the local server that caused this.

Connection succeeded.
Connecting: host=localhost port=5432 user=postgres dbname=AdminBoundaries

==============================
Importing with configuration: adminboundaries, public, geom, H:\AdminBoundaries, mode=c, dump=1, simple=0, geography=0, index=1, shape=1, srid=0
Shapefile type: Polygon
PostGIS type: MULTIPOLYGON[2]
Failed SQL begins: "SET CLIENT_ENCODING TO UTF8;
SET STANDARD_CONFORMING_STRINGS TO ON;
BEGIN;
CREATE TABLE "public"."adminboundaries" (gid serial,
"ID_0" int4,
"ISO" varchar(3),
"NAME_0" varchar(75),
"ID_1" int4,
"NAME_1" varchar(75),
"VARNAME_1" varchar(150),
"NL_NAME_1" v"
Failed in pgui_exec(): ERROR: function addgeometrycolumn(unknown, unknown, unknown, unknown, unknown, integer) does not exist
LINE 59: SELECT AddGeometryColumn('public','adminboundaries','geom','…
^
HINT: No function matches the given name and argument types. You might need to add explicit type casts.

Shapefile import failed.

==============================
Importing with configuration: adminboundaries, public, geom, H:\AdminBoundaries, mode=c, dump=1, simple=0, geography=0, index=1, shape=1, srid=0
Shapefile type: Polygon
PostGIS type: MULTIPOLYGON[2]
Failed SQL begins: "SET CLIENT_ENCODING TO UTF8;
SET STANDARD_CONFORMING_STRINGS TO ON;
BEGIN;
CREATE TABLE "public"."adminboundaries" (gid serial,
"ID_0" int4,
"ISO" varchar(3),
"NAME_0" varchar(75),
"ID_1" int4,
"NAME_1" varchar(75),
"VARNAME_1" varchar(150),
"NL_NAME_1" v"
Failed in pgui_exec(): ERROR: function addgeometrycolumn(unknown, unknown, unknown, unknown, unknown, integer) does not exist
LINE 59: SELECT AddGeometryColumn('public','adminboundaries','geom','…
^
HINT: No function matches the given name and argument types. You might need to add explicit type casts.

Shapefile import failed.

Best Answer

It seems like your database is not PostGIS enabled. Make sure you created the database from your PostGIS template. You'll be able to tell by looking at the list of available functions. If you don't find an AddGeometryColumn function there, PostGIS support is missing.

Related Question