Hello Andrea and all,


thank you all for your help. I could solve my problem with the field calculator 
and the command Jürgen sent me in the QGIS user group.



Since the GDAL/ogr MS SQL Server driver is obviously missing on my computer, I 
will see if I can get a complete installation of the current GDAL package. This 
would be very helpful in many situations, especially in scripts that perform 
transformation tasks.



Best regards



Michael


Von: gdal-dev <[email protected]> Im Auftrag von Andrea 
Giudiceandrea via gdal-dev
Gesendet: Donnerstag, 20. Oktober 2022 18:36
An: [email protected]
Betreff: Re: [gdal-dev] ogr2ogr doesn't connect to MS SQL Server


ACHTUNG!! Diese E-Mail erreicht Sie von einem Absender außerhalb der 
niedersächsischen Landesverwaltungs-Infrastruktur mit TLS-Verschlüsselung. 
Bitte klicken Sie auf keine Links oder öffnen Sie keine E-Mail-Anhänge, falls 
Sie den Absender nicht kennen und nicht wissen, ob der Inhalt sicher ist.
Hi Michael,
the GDAL/OGR library needs the "ogr_MSSQLSpatial.dll" file to properly activate 
the MSSQLSpatial GDAL/OGR driver ("MSSQL:").

You can check if the MSSQLSpatial GDAL/OGR driver is supported by your ogr2ogr 
tool using the following command in the OSGeo4W Shell:

ogr2ogr --formats | find "MSSQL"

If it outputs the string "MSSQLSpatial -vector- (rw+): Microsoft SQL Server 
Spatial Database (BCP)", then it means such driver is supported, otherwise not.

If you cannot use the OSGeo4W "Setup" program to install such file, you can try 
to fix the issue just downloading the "gdal-mss" OSGeo4W package from [1] and 
extracting from it the "ogr_MSSQLSpatial.dll" file to the 
"\apps\gdal\lib\gdalplugins\" folder in your QGIS installation dir.
The exact "gdal-mss" OSGeo4W package to download depends on the exact GDAL 
version installed with QGIS.

Best regards.

[1] https://download.osgeo.org/osgeo4w/v2/x86_64/release/gdal/gdal-mss/?C=M&O=D

Il 20/10/2022 16:56, Reetz, Michael (NLPV) ha scritto:
I’ve found msodbcsql17.dll in C:\Program Files\QGIS 3.22.8\bin\1033 and 
C:\Program Files\QGIS 3.22.8\bin.
Gdal-mss seems not to be on my computer. But since SQL Server Native Client 
isn’t supported by MS SQL Server 2019 , this shouldn’t be a Problem.
_______________________________________________
gdal-dev mailing list
[email protected]
https://lists.osgeo.org/mailman/listinfo/gdal-dev

Reply via email to