Anomalie #7293
Unit test fail if oneToMany doesn't have mappedBy
Start date:
01/12/2016
Due date:
% Done:
0%
Estimated time:
Recurrences
History
#2
Updated by Jérome A. almost 4 years ago
Cannot reproduce on 0.8 at android project level with
/* Translation.java */
@Table
@Entity
public class Translation {
@Id
@GeneratedValue(strategy = GeneratedValue.Strategy.MODE_IDENTITY)
@Column (type = Type.INTEGER, hidden = true)
private int id;
@OneToMany(targetEntity = "TranslationItem")
private ArrayList<TranslationItem> items;
}
/* TranslationItem.java */
@Table
@Entity
public class TranslationItem {
@Id
@GeneratedValue(strategy = GeneratedValue.Strategy.MODE_IDENTITY)
@Column (type = Type.INTEGER, hidden = true)
private int id;
@ManyToOne(targetEntity = "Translation", inversedBy = "items")
private Translation translation;
}
Also tested without the "inversedBy" on TranslationItem entity