[Mapserver-users] Accessing PostGIS layers via OGR in MapServer
Frank Warmerdam
warmerdam at pobox.com
Tue Apr 6 13:02:29 PDT 2004
Mike Leahy wrote:
> Hello list,
>
> I'm trying to see if I can access PostGIS layers via the OGR input type in
> the MapServer 4.1 development version. The warning message below is about
> as far as I can get:
>
> Warning: [MapServer Error]: msOGRFileOpen(): Open failed for OGR connection
> `PG:dbname=educal user=Administrador host=localhost'. File not found or
> unsupported format
>
> I've tried several formats of connection strings in addition to the one in
> the example above:
>
> PG:'dbname=educal user=Administrador host=localhost'
> PG:dbname=educal;user=Administrador;host=localhost
> PG:dbname=educal
>
> So far, none have worked. I've got PostGIS 0.8 installed as well as GDAL in
> CygWin, with MapServer running as CGI in IIS on WinXP. I can run OGR
> components from CygWin okay (e.g., ogr2ogr), but I just don't seem to have
> any luck with it in MapServer yet. I'm hoping it's just a problem with my
> connection string. When I connect using PostGIS directly, the connection
> string "user=Administrador dbname=educal host=localhost" works fine.
Mike,
How confident are you that your OGR build includes PostGIS support? Try
"ogrinfo --formats" and see if there is a "PostgreSQL" driver listed.
Best regards,
--
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up | Frank Warmerdam, warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush | Geospatial Programmer for Rent
More information about the MapServer-users
mailing list