I have .shp files that I want to upload to SQL Server
I am trying to find an easy solution to uploading .shp file to SQL Server 2018. I tried OGR2OGR and I get an error. Below is my OGR2OGR command and then the error.
ogr2ogr -progress -f "MSSQLSpatial" "MSSQL:server=xyz.database.windows.net;driver=SQL SERVER;database=Spatia;UID=test;PWD=test;trusted_connection=yes;" "C:\Users\AX\Desktop\SFTP Keys\spatial\aus_16_mb.shp" -a_srs "EPSG:4326"
ERROR 1: Unable to initialize connection to the server for MSSQL:server=xyz.database.windows.net;Database=Spatial;trusted_connection=yes,
Try specifying the driver in the connection string from the list of available drivers:
SQL Server
SQL Server Native Client 11.0
SQL Server Native Client RDA 11.0
ODBC Driver 13 for SQL Server
PostgreSQL ANSI(x64)
PostgreSQL Unicode(x64)
Amazon Redshift (x64)
ODBC Driver 17 for SQL Server
ERROR 1: MSSQL Spatial driver doesn't currently support database creation.
Please create database with the Microsoft SQL Server Client Tools.
ERROR 1: MSSQLSpatial driver failed to create MSSQL:server=xyz.database.windows.net;Database=Spatial;trusted_connection=yes