mod=type;
typedef odb::query<donnee_stat> query;
typedef odb::result<donnee_stat> result;
transaction t (db->begin ());
odb::result<donnee_stat> r (db->query<donnee_stat> (query::module == mod));
QVBoxLayout *layout = new QVBoxLayout;
QStandardItemModel *modele = new QStandardItemModel();
for (result::iterator i (r.begin ()); i != r.end (); ++i)
{
cout << i->date<< " "<<i->fonction << " "<< i->module << endl;
modele->setItem(i->fonction,1, new QStandardItem("da" ));
}
t.commit ();
QTableView *vue = new QTableView;
vue->setModel(modele);
layout->addWidget(vue);
setLayout(layout);
show();