hii friends

i have a QDataTable widget in the dialog that contains data from mysql database.
now when the dialog gets loaded i want that the data table should show the changes immediately if the database gets changed. i.e. data table should update itself around every (for example) 3secs.

i have tried out calling the method "refresh()" like this : dataTable1->refresh()
(dataTable1 is the name which i have given to this QDataTable widget in the dialog.)

it dint worked.
i am editing the code in kdevelop and from there also i tried calling the function "update()"
but the error says " update undeclared ".

the code which i have got has got this function "update()" to refresh the table and there it is working. but in my code it is not. i have included the header files pthread.h and unistd.h (i donno wheather it has got anything to do with it or not).

please tell me how to refresh this qdatatable.

thanks and regards.
shamik