Because, once I enable my sessionCustomizer class, eclipselink no longer uses the correct statement (CALL NEXT VALUE FOR), but instead uses :
All I changed in the session Customizer class was setSequenceNumberName.
I came up with a workaround where I now, instead of using auto increment when creating the tables, I createmy own sequences and set the default value of the column to :
"DEFAULT (NEXT VALUE FOR PUBLIC.MY_SEQUENCE_TABNAME ) NOT NULL NULL_TO_DEFAULT SEQUENCE PUBLIC.MY_SEQUENCE_TABNAME";
Then in my persistence entity classes, I set the sequence name.
@GeneratedValue(strategy = GenerationType.AUTO, generator="GEN_TABNAME")
@SequenceGenerator(name = "GEN_TABNAME", sequenceName = "MY_SEQUENCE_TABNAME", allocationSize = 1)
It's not ideal, I would still prefer a way where eclipselink figures out the sequence name of an auto_increment field and uses that correctly, but it works.
Thanks,
Droes