[mapserver-users] data parameter in tileindex
Peter Schmitt
pschmitt at gmail.com
Mon Apr 5 16:06:31 PDT 2021
On Wed, Mar 24, 2021 at 1:47 AM Rahkonen Jukka (MML) <
jukka.rahkonen at maanmittauslaitos.fi> wrote:
> perhaps OGR connection to PostGIS would work better than the native one
> with tileindex.
>
I am trying to do this as a proof-of-concept tile index of vector files
where the geom is stored in a Postgis database. Does anyone have
experience with the Postgres driver and a MapServer OGR layer? I can get
OGR to read my database with something like this:
ogrinfo -ro PG:"host='db' user='test' dbname='testdb' password='123'" -sql
"SELECT id, geom FROM boundaries LIMIT 1"
# service=WFS&VERSION=1.1.0&REQUEST=getfeature&typename=example_layer
LAYER
NAME example_layer
TYPE POLYGON
CONNECTIONTYPE OGR
CONNECTION "host=db user=test dbname=testdb password=123"
END
I've tried passing the query (-sql "SELECT id, geom FROM boundaries LIMIT
1") in the CONNECTION string, as a separate DATA and also CONNECTIONOPTIONS
as in the ElasticSearch example in the docs
https://www.mapserver.org/input/vector/ogr.html However none of these
work. How do you pass something like "-sql ..." to a MapServer layer of
type OGR?
Thanks!
Pete
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20210405/e0f6cd80/attachment.htm>
More information about the MapServer-users
mailing list