How are you querying the database with Qt ?