Thanks, Michael
Yes, it is a spell mistake. But there is no such mistakes in my application.
what i want is i can create an Account with specified user like this:
Account account = new Account();
account.setHandledby(user);//pre got User
account.setDeposit(new Double(0));
AccountDao.create("insertAccount",account);
by the way, how can i turn log4j on in web application(WAR)?
i tried to put my log4j.properties in WEB-INF/, but no logs displayed on console
Thanks again.
Alex
> > POJO:
> > public class Account implements Serializable {
> > private Long id;
> > private String name;
> > private Double deposit;
> > private User handledby;
> > }
> > public class User implements Serializable {
> > private Long id;
> > private String username;
> > private String password;
> > }
> >
> > SQL:
> > <insert id="insertAccount" parameterClass="account">
> > insert into ACCOUNT (ID,NAME, DEPOSITE, FK_HANDLEBY)
> > values (#id#, #name#, #deposit#, #handledby.id#)
> > </insert>
