ramnath wrote:
Your code would help us....
I had Scheme table that has no primary key .It had 3 fields
schemeCode,schemeName,schemeRate.The hibernate-reveng.xml file
created 2 POJOS.ie Scheme.java,SchemeId.java.
The code for Scheme.java like this-----
private SchemeId id;
public Scheme() {
}
public Scheme(SchemeId id) {
this.id = id;
}
//getter& setter for id property
The code for SchemeId.java like this-----
private String schemeCode;
private String schemeName;
private BigDecimal schemeRate;
//getter& setters for above 3 properties
I am trying to execute query ie like this
sql="from Scheme obj where obj.id.schemeCode='A002'"
qry=session.createQuery(sql);
Output of qry.list() showing null
But
qry.list.size()------It showing correct list size