Hi,
I have a problem with the following mapping:
db:
---
KONZERN_NR | CHAR(6)
KONZERN_BEZEICHNUNG | VARCHAR2(50)
mapping:
--------
<class name="com.xxx.Konzern" identity="konzernNr">
<map-to table="KONZERN"/>
<field name="konzernNr" type="string">
<sql name="konzern_nr" type="char"/>
</field>
<field name="bezeichnung" type="string">
<sql name="konzern_bezeichnung" type="char"/>
</field>
</class>
class:
------
public class Konzern {
private String konzernNr;
private String bezeichnung;
public String getKonzernNr() {
return konzernNr;
}
public void setKonzernNr(String konzernNr) {
this.konzernNr = konzernNr;
}
public String getBezeichnung() {
return bezeichnung;
}
public void setBezeichnung(String bezeichung) {
this.bezeichnung = bezeichnung;
}
}
Castor uses the following statement:
SELECT
"KONZERN"."KONZERN_NR","KONZERN"."KONZERN_BEZEICHNUNG","KONZERN"."KONZERN_BE
ZEICHNUNG" FROM "KONZERN" WHERE (lower("KONZERN"."KONZERN_BEZEICHNUNG" )
like ?) ORDER BY "KONZERN"."KONZERN_BEZEICHNUNG"
After that he creates an object with the right identity (konzernNr) but the
property "bezeichnung" is set to null even if the value in the database is
set to something else than null.
Any ideas??
Regards
Christoph
-----------------------------------------------------------
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
unsubscribe castor-dev