You have to transfer only those rows that you need and those that have changed. I don't think you need to view all 3M rows at once, so teaching your model to use canFetchMore() and fetchMore() can give a rather significant improvement. The same goes with submiting changes to the remote model. Relying on QSqlTableModel that uses a generic SQL driver is not a good idea as different SQL drivers have different capabilities and can take a rather inefficient code path.
Bookmarks