

This fixed it: GRANT ALL ON TABLE spatial_ref_sys TO my_user_name The issue this time was that this database user didn't have sufficient permissions. PL/pgSQL function addgeometrycolumn(character varying,character varying,character varying,integer,character varying,integer,boolean) line 5 at SQL statement PL/pgSQL function addgeometrycolumn(character varying,character varying,character varying,character varying,integer,character varying,integer,boolean) line 50 at SQL statement I also tried to import it through the GUI shp2pgsql and I get the following error: ALTER TABLE "public".""įailed in pgui_exec(): ERROR: permission denied for relation spatial_ref_sysĬONTEXT: SQL statement "SELECT SRID FROM spatial_ref_sys WHERE SRID = new_srid" Translation of layer world_boundaries (use -skipfailures to skip errors) I have also tried to define the full path of the shapefile but I got the same message.Īlso I tried to run the: ogrinfo world_boundaries.shpĪfter fixing the issues with the permissions of the file I get the following error: ERROR 1: AddGeometr圜olumn failed for layer world_boundaries, layer creation has failed.ĮRROR 1: Terminating translation prematurely after failed


#DRIVER GENIUS INVALID DATABASE ERROR DRIVERS#
What I get back is an error message: Unable to open datasource `world_boundaries.shp' with the following drivers: -a list of drivers follows (ESRI Shape File etc.) I have successfully installed ogr2ogr and I run from the pgsql the following command: ogr2ogr -f "PostgreSQL" PG:"host=localhost user=user_1 password=***** dbname=imports" world_boundaries.shp I want to use ogr2ogr in order to import a shapefile in a postgis database.
