Originally posted by Jared Chapman:
To refresh the table with the new data, just do:
You shouldn't replace the tableModel.
You should inform the tableModel that you want to clear its data collection and then add the new data. When you clear the collection use fireTableDataChanged to make the table redisplay.
Completely replacing the model may work in simple cases, but you could lose other information known to the model in more complex cases.