Hello,
This code inserts records in a MySQL table:
Qt Code:
int row = 0; model->insertRows(row,1); view->setCurrentIndex(index); view->edit(index);To copy to clipboard, switch view to plain text mode
If i repeat the the value in the Primary Key or leave NULL a mandatory field, the data will remain visible in the view but, as soon as i refresh the model, i realise it was not there.
How showld i control this?
Bookmarks