QSqlDatabase db = QSqlDatabase::addDatabase(driver,"Имя соединения");
QString conName = db.connectionName();