Setting the search path via ALTER DATABASE seems to fix the problem just great. I guess I had set it via my .psqlrc and that didn't work for a QGIS connection.
Tx! -W On Mon, Dec 28, 2009 at 9:24 AM, Mike Toews <[email protected]> wrote: > There are two things I can think of, both of which I haven't tested. > > 1. Modify your database search path to include the postgis schema by > default: > > ALTER DATABASE mydatabase SET search_path=public,postgis; > > or > > 2. Create views to the two tables in the public schema (assuming you kept > this as from the default): > > CREATE OR REPLACE VIEW spatial_ref_sys AS SELECT * FROM > postgis.geometry_columns; > CREATE OR REPLACE VIEW spatial_ref_sys AS SELECT * FROM > postgis.geometry_columns; > > > -Mike > > FW wrote: >> >> In my postgis installations, I like to keep my postgis junk in its own >> schema (aptly named "postgis"), and then to set postgis to the last >> element in the search path. This way you can drop the entire thing by >> dropping the schema, you can search for functions in postgis.*, etc. >> >> However, when I connect QGIS to my DB, it can't find my >> geometry_columns, spatial_ref_sys, or the fact that I have a geometry >> type. These are all quite visible from the psql prompt using \dT and >> the like >> >> Is there a way to have QGIS look in the schema postgis for this? >> >> I am running 1.3.0 on freebsd, with both spatialite and postgis supported. >> >> Tx! >> _______________________________________________ >> Qgis-user mailing list >> [email protected] >> http://lists.osgeo.org/mailman/listinfo/qgis-user >> > > _______________________________________________ Qgis-user mailing list [email protected] http://lists.osgeo.org/mailman/listinfo/qgis-user
