How to abort/cancel HSQLDB query
问题 I have a Java SE application using JPA provided by Hibernate and a HSQL database. The application queries the database with EntityManagers for information in order to draw charts on the screen. While the query is executing, the area for the chart has the typical spinning icon to let the user know that it's working. Some queries take a long time, and I want to have the feature to abort/cancel the query. I know I can unwrap the EntityManager and get the Hibernate Session and call cancelQuery(),