| JPA spec does in fact require that the numbers used be contiguous (you cannot have gaps such as missing 4 in your example). It does not require that the occur sequentially (e.g. 5 can come before 4). This is exactly what Hibernate expects. If you have a test showing that is not the case in the most recent version (5.2 as of this moment), then please open a new issue and attach that test. |