|
Hi, I've following mapping
file:
<?xml version="1.0"
encoding="UTF-8"?>
<!DOCTYPE mapping PUBLIC "-//EXOLAB/Castor Object Mapping DTD Version 1.0//EN" "file:///C:/Java/Schema/Castor/mapping.dtd"> <mapping> <class name="com.ezan.contract.ContractStore" identity="contract_no"> <map-to table="contract_tbl"/> <field name="contract_no" type="string"> <sql name="contract_no"/> </field> <field name="c_name" type="string"> <sql name="c_name"/> </field> <field name="stages" collection="collection" type="com.ezan.contract.StageStore"/> </class> <class name="com.ezan.contract.StageStore" identity="contract_no stage_no" depends="com.ezan.contract.ContractStore"> <map-to table="stages_tbl"/> <field name="contract_no" type="string"> <sql name="contract_no"/> </field> <field name="stage_no" type="integer"> <sql name="stage_no"/> </field> <field name="s_name" type="string"> <sql name="s_name"/> </field> <field name="sum_rub" type="java.math.BigDecimal"> <sql name="sum_rub"/> </field> <field name="dat_act" type="date"> <sql name="dat_act"/> </field> </class> </mapping> //----------------- In app I do:
ContractStore cs=
(ContractStore)db.load( ContractStore.class,
"Contract2");
Collection c= cs.getStages(); and Collection is empty while it still have some
elements...
What's the problem?
Thank you.
|
