Each time an item in the JComboBox is selected, --or if editable Enter is pressed-- an ActionEvent is fired. Thus the exception will be thrown, I guess because such table does not exist. Remove the query code from the listener and place it in a actionListener for a new button.
You are warnned against clogging the Event-Dispatching
thread: place any lengthy task in another thread.