- all your posts here about to create DefaultTableModel is wrong, all these methods are implemented and correctly, no idea, no reason to override that
- never to call fireXxxXxx for DefaultTableModel, these methods are implemented and correctly
- for why reason you override
public void addRow(Vector rowData) { and
public void addRow(Object[] rowData) { inside one XxxTableModel
- you are using these Object wrong
- (even model is created before) you called
DefaultTableModel model = (DefaultTableModel) jTable1.getModel(); in
outputSelection() { then you have to lost reference betweens GUI and model
- even valueChanged() from ListSelectionListener fired the proper event, Id be to
test if (row> -1)
- have to change ListSelectionModel to SINGLE_Xxx, then isnt possible to select more than one row
- database whatever (
db.updatePatientData(savedValues);) must be based on PrepareStatement
- be sure that PrepareStatement.close() (in finally block), otherwise these Object never gone from JVM memory, nor GC'ed