Skip to main content

I uploaded a table into MSSQL server, but the table is not visible in QGIS.

There is no issue viewing the table in SQL Server Management Studio, and the primary key is generated by counter.

So far, I tried turn Spatial Index on and off; Change the collection type handling; Change Insert into Identify Column on/off. None of those steps work.

Any idea how to modify the writer to let the table visible in QGIS?

 

Update:

In ArcGIS Pro, the table is visible, but can't add to map, gives an error message.

Just to confirm, if you duplicate the table in SQL Server Management Studio, can you see the table in QGIS? Or still nothing? Additionally, if you write to a new test table instead of dropping and creating is there any difference?
Just to confirm, if you duplicate the table in SQL Server Management Studio, can you see the table in QGIS? Or still nothing? Additionally, if you write to a new test table instead of dropping and creating is there any difference?

Still nothing,

There are warnings after running the workbench:

Microsoft SQL Server Spatial Writer: Failed to connect using Microsoft OLE DB Driver for SQL Server. Provider error 'Description: Class not registered'. Connection string 'Provider=MSOLEDBSQL;

Microsoft SQL Server Spatial Reader: Failed to connect using Microsoft OLE DB Driver for SQL Server. Provider error '(-2146824582) Provider cannot be found. It may not be properly installed.'. Connection string


in QGIS if you add the layer via the Layer Menu using the "Add MSSQL Spatial Layer" option you can see which column QGIS is using for primary_key and change it. It sounds like QGIS is picking the wrong column.


in QGIS if you add the layer via the Layer Menu using the "Add MSSQL Spatial Layer" option you can see which column QGIS is using for primary_key and change it. It sounds like QGIS is picking the wrong column.

Which QGIS version should I use? Couldn't change the primary_key.


Reply