Using gdal docker image to access SQL Server

50 views Asked by At

I need to convert some spatial information stored into SQL Server database into an Esri Shapefile.

For that I am using the ogr2gr program from gdal.org.

I have made some test installing the client in windows and it have worked well. Now, for requirement I need to use an gdal docker container to create the shapefile.

I have made some test but they have not working. I have seen that the driver MSSQLSpatial is not present in the gdal docker images.

Is there any way to add to the container the MSSQLSpatial driver?

Also, I am considering to use the WKT or any format that can be obtained with SQL Server to obtain the Esri shapefile, to avoid the connection to SQL Server database from the container.

I have tried without success the following:

ogr2ogr -f "ESRI Shapefile" "d:\tmp\test\esri" 
           "0xE61000000104090000008C3B6B45E8D1574082F6D5F70F231640B040943240DD5740022FB42EC6EA1640C4EA3F0D2DD25740C0F7E71930D31740B42C2A126EBC57408009117879051740304AE3F9278857407FB52BABEB4B1740C853AEAE527C5740020F5FC617781640B8A73A0A8EBC574002E93FBAC4D81640A885BC6CDBC1574082EE741A7B3216408C3B6B45E8D1574082F6D5F70F23164001000000020000000001000000FFFFFFFF0000000003" 
        -overwrite

I am struggling to find what can be placed as datasource for ogr2ogr.

Any thoughts here?

0

There are 0 answers