Quote Originally Posted by foggy-mind View Post
First problem:
The 2'nd column has data which is int type, and sorting is something like that [1,10,11,...,2,21,...] I need that numbers will be sorted [1,2,...,10,11,...,21,...]
use

Qt Code:
  1. item = new QStandardItem;
  2. item->setValue(query->record().value("ltr_cust_code").toInt());
  3. itemModel->setItem(row, 1, item);
To copy to clipboard, switch view to plain text mode 

if all your entries are integers...