ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tony Qian" <daqiqi...@aol.com>
Subject query by example
Date Wed, 22 Feb 2006 17:29:09 GMT
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <title></title>
</head>
<body>
<font face="Courier New" size="2">I just downloaded abator and
denegrated xml, dao, and
<br>
model codes. I can not figure out how to use query by
<br>
example style selection. <br>
<br>
Here is one method in dao.
<br>
<br>
&nbsp;&nbsp; /**
<br>
&nbsp;&nbsp;&nbsp;&nbsp; * This method was generated by Abator for iBATIS.
<br>
&nbsp;&nbsp;&nbsp;&nbsp; * This method corresponds to the database table
<br>
carproject.car
<br>
&nbsp;&nbsp;&nbsp;&nbsp; *
<br>
&nbsp;&nbsp;&nbsp;&nbsp; * @abatorgenerated Wed Feb 22 03:05:24 EST 2006
<br>
&nbsp;&nbsp;&nbsp;&nbsp; */
<br>
&nbsp;&nbsp;&nbsp; public List selectByExample(CarExample example) {
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; return selectByExample(example,
null);
<br>
&nbsp;&nbsp;&nbsp; }
<br>
<br>
one of the methods in CarExample
<br>
<br>
&nbsp;&nbsp; /**
<br>
&nbsp;&nbsp;&nbsp;&nbsp; * This method was generated by Abator for iBATIS.
<br>
&nbsp;&nbsp;&nbsp;&nbsp; * This method corresponds to the database table
<br>
carproject.car
<br>
&nbsp;&nbsp;&nbsp;&nbsp; *
<br>
&nbsp;&nbsp;&nbsp;&nbsp; * @abatorgenerated Wed Feb 22 03:05:24 EST 2006
<br>
&nbsp;&nbsp;&nbsp;&nbsp; */
<br>
&nbsp;&nbsp;&nbsp; public void setMileage_Indicator(int
<br>
mileage_Indicator) {
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; this.mileage_Indicator
= mileage_Indicator;
<br>
&nbsp;&nbsp;&nbsp; }
<br>
<br>
Can someone give me some very brief code to select a car
<br>
with mileage less than 50,000 miles? <br>
<br>
Appreciate your help,
<br>
Tony </font>
</body>
</html>


Mime
View raw message