Are there more resources for programming with Databases?
I've used Qt before for a few simple projects but now I'm really getting my hands dirty. I've seen this: "Connecting To Databases with SQL":http://doc.qt.nokia.com/4.7/sql-connecting.html but I'm looking for more. Has anyone found a really good resource for Qt w/DB, specifically Postgres, but any SQL centric paper/tutorial/etc will do fine. Also, any good book recommendations outside of the "C++ Programming with Qt 4 Second Ed":http://www.amazon.com/gp/product/0132354160/ref=ase_trolltech/ book?
Purpose of the SQL layer is to abstract the various database servers into a unified API. It should be straight forward to adapt the samples to your individual database environment.
Apart from the lower level direct database classes like "QSqlDatabase":http://doc.qt.nokia.com/4.7/qsqldatabase.html and "QSqlQuery":http://doc.qt.nokia.com/4.7/qsqlquery.html, there are convenience classes for the "model/view":http://doc.qt.nokia.com/4.7/model-view-programming.html classes of Qt: "QSqlQueryModel":http://doc.qt.nokia.com/4.7/qsqlquerymodel.html, "QSqlTableModel":http://doc.qt.nokia.com/4.7/qsqltablemodel.html and "QSqlRelationalTableModel":http://doc.qt.nokia.com/4.7/qsqlrelationaltablemodel.html
Your question is quite vague, so it's hard to give you any advice. Do you have any specific questions or problem you're facing?
I think this might be a good start. Initially I want to make a GUI front end to manage an existing set of databases. I'll need to connect to a DB server with a username/pass and return a list of databases, then backup/restore/etc them.
While you can get the databases/tables from the catalog quite easily, I would go with the native tools for backup/restore procedures (you can call the command line tools with QProcess). There is hardly any support for this from Qt side.