| It seems that the behaviour of entitymanager.find(<Entity>, id) is different than the same query in JPQL. The find method of the entitymanager returns the object from the current persistence context if it is already available in the current persistence context and does not query the database in this case. The same query with JPQL also returns the object from the current persistence context but also queries the database. Is this behaviour intended or is this a bug? We added a testcase on https://github.com/JavaTesting1/hibernate-test-case-templates |