Using a second query while scrolling causes the ScrollableResults to be closed.
Perhaps I am not supposed to unwrap the JPA2 query like that?
WIth Hibernate 5.1.0 and the following code to obtain a ScrollableResults, the example code works as expected:
However, running 5.4.18, it does not appear to matter what query I issue inside the loop, it will close the result set.
The resulting exception from 5.4.18:
Thanks for any help!
I have tested the following code using the JPA2 getResultStream(), and it also produces the same exception:
The exception from using getResultStream():
CentOS 7, Fedora 30