This one replicates on 5.0.6. I added a test case using the Hibernate unit test templates and this issue is still relevant.