Что-то вроде этого поможет:
void selectMatchingRows(JTable table, String regex)
{
for (int row = 0; row < table.getModel().getRowCount(); row++)
{
for (int col = 0; col < table.getModel().getColumnCount(); col++)
{
if (table.getModel().getValueAt(row, col).toString().matches(regex))
{
table.getSelectionModel().setSelectionInterval(row, row);
}
}
}
}
Убедитесь, что ListSelectionModel.selectionMode
равно MULTIPLE_INTERVAL_SELECTION
.