Details
-
Bug
-
Status: Closed
-
TBD
-
Resolution: Fixed
-
Platform 1.10.4, Platform 1.11.3, Platform 1.11.5
-
None
-
None
Description
Please see for solution:
https://talk.openmrs.org/t/using-joincolumn-instead-of-column-with-manytoone-in-baseopenmrsdata/3150
This issue was introduced in 1.11.3 and has been affecting all version since. Two modules are affected:
org.openmrs.BaseOpenmrsData
org.openmrs.BaseOpenmrsMetadata
For the following properties, replace @Column with @JoinColumn:
@ManyToOne(optional = false)
@Column(name = "creator")
protected User creator;
@ManyToOne
@Column(name = "changed_by")
private User changedBy;
@ManyToOne
@Column(name = "voided_by")
private User voidedBy;
This problem causes build failure for the Oauth2 module, if you change the OpenMRS version from 1.11.1 to 1.11.3 or greater.
https://github.com/maany/openmrs-module-oauth2-prototype/tree/oauth2-openmrs-1.11.x