[gdal-dev] Create PostGIS database using OGR/GDAL
Paul Meems
bontepaarden at gmail.com
Thu Oct 23 13:03:26 PDT 2014
Hi,
At this moment we are working on getting PostGIS support for MapWinGIS.
We use the PostGIS driver from GDALv2.
So far we can read and write layers.
We also want to implement some tests, which are also used as a show case
for other users.
For these tests I want to create a database, import some layers, doe
something with the layers and drop the database again.
Creating and dropping a database using ExecuteSQL() doesn't work as stated
at the driver page:
The PostgreSQL driver does not support creation of new datasets (a database
within PostgreSQL), but it does allow creation of new layers within an
existing database.
The error I'm getting is "CREATE DATABASE cannot run inside a transaction
block".
Does anybody have an idea how to solve this? I don't want to manually
create the database. The tests are more or less running automated. I would
also like to prevent to bypass GDAL/OGR and connect to PostGIS directly to
create and drop a database.
Any suggestions are much appreciated.
Thanks,
Paul
*Paul Meems *
Release manager, configuration manager
and forum moderator of MapWindow GIS.
www.mapwindow.org
Owner of MapWindow.nl - Support for
Dutch speaking users.
www.mapwindow.nl
*The English presentations of the MapWindow GIS Conference 2014 are online.
<http://www.slideshare.net/mapwindow>*
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20141023/1b1bcbb0/attachment.html>
More information about the gdal-dev
mailing list