开发者

Problem in remove sqlite connection in QT

开发者 https://www.devze.com 2023-04-07 04:20 出处:网络
I\'ve got following error when i want to remove my QSqlDatabase that connected to the Sqltie: QSqlDatabasePrivate::removeDatabase: 开发者_如何学编程connection \'cnnDFP\' is still in use, all queries

I've got following error when i want to remove my QSqlDatabase that connected to the Sqltie:

QSqlDatabasePrivate::removeDatabase: 开发者_如何学编程connection 'cnnDFP' is still in use, all queries will cease to work.

*cnnDFP is my connection name

How can i fix this? please help me


You're not showing you're code, so it is difficult to guess what is wrong. Anyway, have you read the documentation: http://doc.qt.io/qt-5/qsqldatabase.html#removeDatabase? Did you close all the queries before trying to remove the connection?

0

精彩评论

暂无评论...
验证码 换一张
取 消