You should use a custom type handler for conversion from text to boolean. We'll be including a standard one in a future release.
Clinton On Fri, 25 Mar 2005 10:20:46 -0500, Mike Zatko <[EMAIL PROTECTED]> wrote: > I have a db table that has a field that has a SMALLINT datatype. This > field is being used as a true/false flag. 0 would be true, anything else > would be false as would typically happen in C. I set up a result map > that looks like the following: > > <resultMap id="getBenefitAppliesMap" > class="com.boscovs.commerce.promotion.dao.benefit.apply.BenefitApplyDAO"> > <result property="totalOrderOn" column="TOTAL_ORDER_ON" > jdbcType="SMALLINT" javaType="java.lang.Boolean" nullValue="false"/> > </resultMap> > > I was thrilled that it worked, but the results were opposite of what I > expected. A '0' value would denote false, while anything else was true. > Anybody know whats going on? > > -- > Michael H. Zatko > Java Enterprise Developer > Boscov's Information Services > Work: 610-929-7317 > Home: 610-376-1624 > Page: 610-736-4460 > >