In the table's rowSelectionChange event handler, check the size of the result from method getSelectedIndices.
If the array size is bigger than zero (which means one or more rows are selected), set the visible property of your second table to true. If size is 0, set to false.