error while execution duplicate connection name
hi
could you help me with this error :
when i compile it's all good but while the execution i get this messsage
QSqlDatabasePrivate::addDatabase: duplicate connection name 'qt_sql_default_connection', old connection removed.
and the programm stops the execution
Re: error while execution duplicate connection name
If you want to have multiple database connections, name them when calling QSqlDatabase::addDatabase( "name" ) and then retreive them via QSqlDatabase::database( "name" ).
If you use only single connection then use QSqlDatabase::addDatabase() only once and later retreive it via QSqlDatabase::database().
Read manual for QSqlDatabase::database() and QSqlDatabase::addDatabase() for more info.