[Qt-interest] table values are not shown in database.
Someone
Someone
Sat Jun 25 18:03:50 CEST 2011
According to the qt documentation setTable method does not select data
from the table so you need to use select() after setTable.
Kind Regards,
Pawel
On Sat, Jun 25, 2011 at 4:27 PM, Sujan Dasmahapatra
<sujan.dasmahapatra at gmail.com> wrote:
> QSqlTableModel *model = new QSqlTableModel(this, db); // db is the database
> successfully opened.
>
> model->setTable("things");
>
> QTableView *view = new QTableView;
>
> view->setModel(model);
>
> view->show();
> With this pice of code I can only see the header names of the table but down
> there some values are not seen like this only book and qty but there are
> some 3 values are there i cannot see them. PLease give me some suggestions.
>
> Book qty
>
>
> --
> Thanks & Regards
> Sujan Dasmahapatra
> B.E. (Aeronautics)
> Bangalore, India
> Ph:91-9900839788
> mail id : sujan.dasmahapatra at gmail.com
> yahoo msn : dasmahapatra.aerodynamics at yahoo.co.in
> icq # 556023244
> skype:sujan.dasmahapatra at skyepe.com
> msn: sujan.dasmahapatra at hotmail.com
>
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at qt.nokia.com
> http://lists.qt.nokia.com/mailman/listinfo/qt-interest
>
>
More information about the Qt-interest-old
mailing list