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 &quot;ESRI Shapefile&quot; --debug on candidates PG:&quot;dbname=osmus active_schema=us user=osm password=osm&quot; candidates<br>

PG: DBName=&quot;osmus&quot;<br>ERROR 1: ERROR:  invalid value for parameter &quot;search_path&quot;: &quot;us, public&quot;<br>DETAIL:  schema &quot;public&quot; does not exist<br><br>FAILURE:<br>Unable to open datasource `PG:dbname=osmus active_schema=us user=osm password=osm&#39; 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 &#39;public&#39; schema to the database remedied the situation.<br><br>Is this a bug? Do you need more information?<br><br>Best,<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>