[PyQt] QTableView/QSqlTableModel

James Thompson jamest at ajrs.com
Wed May 2 14:04:31 BST 2007


I'm making my first attempt at utilizing the QtSql module and have a few 
questions I'm having trouble finding info on in the docs.

Is it possible to shuffle the order of the displayed columns around.  The 
table that I'm pulling from has columns in order a, b, c, d, e.  I need to 
actually display  b, e, c, a and skip the d. 

Is it possible to add unbound fields to a QSqlTableModel.  My QTableView only 
needs to alter data in one table.  However I want unbound columns in the 
table view to display lookup data for validation.  User enters invoice number 
in the first column and serval other info columns in the row fill in with 
stuff like the customers name, state of the invoice, etc, etc

Thanks in advance,

More information about the PyQt mailing list