Martijn,<br><br>Thanks for the excellent error report.<br>I couldn't find any statement for or against the requirement for the public schema. Can you provide a reference to this?<br><br><div class="gmail_quote">On Thu, Apr 12, 2012 at 10:43 AM, Martijn van Exel <span dir="ltr"><<a href="mailto:m@rtijn.org">m@rtijn.org</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi all,<br><br>I had trouble extracting a shape file from a PostGIS table using ogr2ogr (1.9.0 on Ubuntu 10.04 64 bit). Debug output from ogr2ogr:<br>
<br>mvexel@lima:/osm/tmp/candidates$ ogr2ogr -overwrite -f "ESRI Shapefile" --debug on candidates PG:"dbname=osmus active_schema=us user=osm password=osm" candidates<br>
PG: DBName="osmus"<br>ERROR 1: ERROR: invalid value for parameter "search_path": "us, public"<br>DETAIL: schema "public" does not exist<br><br>FAILURE:<br>Unable to open datasource `PG:dbname=osmus active_schema=us user=osm password=osm' with the following drivers.<br>
<br clear="all">What I think happens is that ogr implies that schema public exists (which is not a requirement for PostgreSQL) and appends that to the schemas list to feed to search_path. SET search_path then fails, and the active_schema is not set. Consequently, the table is not found and ogr2ogr is not able to connect. <br>
<br>Adding a 'public' schema to the database remedied the situation.<br><br>Is this a bug? Do you need more information?<br><br>Best,<span class="HOEnZb"><font color="#888888"><br>-- <br>martijn van exel<br>geospatial omnivore<br>
1109 1st ave #2<br>salt lake city, ut 84103<br>
801-550-5815<br><a href="http://oegeo.wordpress.com" target="_blank">http://oegeo.wordpress.com</a><br>
</font></span><br>_______________________________________________<br>
gdal-dev mailing list<br>
<a href="mailto:gdal-dev@lists.osgeo.org">gdal-dev@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/gdal-dev" target="_blank">http://lists.osgeo.org/mailman/listinfo/gdal-dev</a><br></blockquote></div><br><br clear="all"><br>-- <br>Best regards,<br>Chaitanya kumar CH.<br>
<br>+91-9494447584<br>17.2416N 80.1426E<br>