Advertisement
Guest User

Untitled

a guest
Apr 24th, 2017
56
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.25 KB | None | 0 0
  1. @Entity
  2. @Audited
  3. @Table(name = "CUSTOM_TAG_INSTANCE")
  4. public class CustomTagInstance implements java.io.Serializable {
  5.  
  6. private Long tagInstanceId;
  7. private instrument instrument;
  8.  
  9. @Id
  10. @Column(name = "TAG_INSTANCE_ID", unique = true, nullable = false, precision = 22, scale = 0)
  11. public Long getTagInstanceId() {
  12. return this.tagInstanceId;
  13. }
  14.  
  15. public void setTagInstanceId(Long tagInstanceId) {
  16. this.tagInstanceId = tagInstanceId;
  17. }
  18.  
  19. @ManyToOne(fetch = FetchType.LAZY)
  20. @JoinColumn(name = "INSTRUMENT_ID")
  21. public Instrument getInstrument() {
  22. return this.instrument;
  23. }
  24.  
  25. public void setInstrument(Instrument instrument) {
  26. this.instrument = instrument;
  27. }
  28.  
  29. AuditQuery query_cusTag = audQueryCreator.forEntitiesAtRevision(CustomTagInstance.class, revision_Id)
  30. .add( AuditEntity.property( "instrument.instrumentId" ).eq( id ) )
  31. .add(AuditEntity.revisionNumber().eq(revision_Id));
  32.  
  33. CustomTagInstance customTagInst = null;
  34. List list_side = query_cusTag.getResultList();
  35. for(int i=0; i<list_side.size(); i++){
  36. customTagInst = (CustomTagInstance) list_side.get(i);
  37. }
  38.  
  39. org.hibernate.QueryException: could not resolve property: instrumentId of: com.epsilon.ets.server.db.table.CustomTagInstance_AUD
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement