It works now. I called emitted the dataChanged method on the wrong part of the data set. However, the table was updated correctly so I dont know why that worked.
Thanks for your help!