Simple database connection tester in c++ - Qt Creator Project