Adding view from MS SQL Server

Hey!

I’ve been trying to add a view from MS SQL Server in QGIS, as proof of concept, just getting a couple of fields out of a table, but whenever I try to add the view it doesn’t show any data, only says repair data source. The normal table does work, but i’d like to use a view. Any help? If any more info is needed please let me know. Neither the table or the view contain a spatial field, i make those with the processing toolbox myself.


Imported from GitHub discussion by @TheRealNext on 2023-04-03T11:53:36Z

Got it fixed, the view needs an autoIndex!


Imported from GitHub comment by @TheRealNext on 2023-04-03T12:28:54Z