ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nicholoz Koka Kiknadze" <kikna...@gmail.com>
Subject Re: Can't delete without the setter method
Date Fri, 05 Dec 2008 07:06:44 GMT
Please enable logging to see what gets executed and specifically what value
for  #jobPostingId# is passed.

On Thu, Dec 4, 2008 at 9:15 PM, Michael He <hyxw5890@yahoo.com.cn> wrote:

>
> Nothing happens without deleting anything
>
> Micheal
>
>
> Kai Grabfelder-2 wrote:
> >
> > hm looks like a bug to me. What happens when you perform the delete? Just
> > nothing or an exception?
> >
> > Regards
> >
> > Kai
> >
> >
> > --- Original Nachricht ---
> > Absender: Michael He
> > Datum: 03.12.2008 15:56
> >>
> >> if i don't set the setter method of the keyword-column property in a
> >> javabean,then i can't delete it using this property?
> >>
> >> for example:
> >>
> >> the javabean:
> >> public class JobPosting implements Serializable {
> >>      private int jobPostingId;
> >>      //missing other properties...
> >>             ...
> >>      public int getJobPostingId() {
> >>              return jobPostingId;
> >>      }//only the getter method
> >>              //missing other getter/setter methods
> >>              ...
> >> }
> >>
> >> the xml:
> >> <delete id="deleteJobPosting" parameterClass="JobPosting">
> >>         delete from jobPosting where jobPostingId=#jobPostingId#
> >> </delete>
> >>
> >> the java code:
> >> public void deleteJobPosting(JobPosting j) {
> >>              getSqlMapClientTemplate().delete("deleteJobPosting", j);
> >>      }
> >>
> >> i have tested it can't be deleted in this case,there is also no error
> >> messages,but i can  insert with the same model, anyone knows why?
> >>
> >> thanks in advance
> >
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/Can%27t-delete-without-the-setter-method-tp20814477p20846623.html
> Sent from the iBATIS - User - Java mailing list archive at Nabble.com.
>
>

Mime
View raw message