Hi Zheng.I think that that is the approach of it.As you saw, the subclass
Remark is a List inside of the Person class,so a Person could have 1 or more
Remark.<isNotEmpty
property= ???>This part above is a problem too, because I just cannot use
"property"to check Null or Empty, given that a property is linked to the class
Person <statement id="insertPerson" class="Person">
And the Person class has its own properties, that are all different
fromRemarks, and I just don't know how to work with them.I've been searching
and reading on some books, and at the moment, Ireally cannot find something
that could help me out on this. :((But thank you very much for your help
:)Subject: RE: Inserting a complex classDate: Tue, 12 Jun 2007 14:21:21
+0200From: [EMAIL PROTECTED]: [email protected]
Hi,
I’m a freshman too. So i give you what i
do. but I don’t know there’s better solution. If there’s better one, please
tell me.
I think you should write
<statement id="insertPerson" class="Person">
insert into PERSON (Id, Name, Surname)
values
(#Id#, #Name#, #Surname#);
<dynamic>
<isNotEmpty
property= ???>
<iterate>
Insert
into
</iterate>
</isNotEmpty
property= ???>
</dynamic>
</statement>
But there’s some problem :
1.
Remark have 2 subclass :
RemarkA and RemarkB. And you use table per concret class for mapping(2 talbes
one for A one for B). You don’t which table to use.
2.
I don’t know yet. I’m finding
the solution for 1.
Is this what you want to know?
WANG
Zheng
_________________________________________________________________
Invite your mail contacts to join your friends list with Windows Live Spaces.
It's easy!
http://spaces.live.com/spacesapi.aspx?wx_action=create&wx_url=/friends.aspx&mkt=en-us