Foreign key annotation fails with ORA-00936
(Doc ID 2353828.1)
Last updated on OCTOBER 21, 2022
Applies to:
Oracle TopLink - Version 12.2.1.0.0 and laterInformation in this document applies to any platform.
Symptoms
When attempting to use foreign key using annotations, for example foreignKey=@ForeignKey(name="FKc2o") the following error occurs.
ERROR
--------
EL Warning]: 2016-08-25 13:12:44.296--ServerSession(936190329)--Thread(Thread[[STANDBY] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)',5,Pooled Threads])--Exception [EclipseLink-4002] (Eclipse Persistence Services - 2.6.3.v20160526-8f41838): org.eclipse.persistence.exceptions.DatabaseException
Internal Exception: java.sql.SQLSyntaxErrorException: ORA-00936: missing expression
Error Code: 936
Call: ALTER TABLE JEE7jpacar ADD CONSTRAINT FKc2o FOREIGN KEY () REFERENCES ()
Query: DataModifyQuery(sql="ALTER TABLE JEE7jpacar ADD CONSTRAINT FKc2o FOREIGN KEY () REFERENCES ()")
Changes
Cause
To view full details, sign in with your My Oracle Support account. |
|
Don't have a My Oracle Support account? Click to get started! |
In this Document
Symptoms |
Changes |
Cause |
Solution |
References |