Re: QSqlRelationalTableModel
The first question is whether the design of your database is correct. You could safely merge those two tables into a single one. As for the relational table model, it can't do what you want. You could implement a proxy that would merge two tables or create a view in your database and use QSqlTableModel or use QSqlQueryModel to fetch both tables. Just remember the latter is read-only.
Re: QSqlRelationalTableModel
Quote:
Originally Posted by
wysota
The first question is whether the design of your database is correct. You could safely merge those two tables into a single one. As for the relational table model, it can't do what you want. You could implement a proxy that would merge two tables or create a view in your database and use
QSqlTableModel or use
QSqlQueryModel to fetch both tables. Just remember the latter is read-only.
tnx, i can't merge the tables, those were just for example, but using QSqlQueryModel solved my problem