ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "davy" <davypulin...@telenet.be>
Subject Re: Question using order by
Date Tue, 07 Aug 2007 11:39:46 GMT
I have added this code to my existing code :
beheerExample.setOrderByClause("substr(referentienummer,16,12)DESC,referentienummer, rowdatumbegin
Now it works, that's what count. I have still a small problem with my date (previous mail).

example.setOrderByClause("substr(refnumber,16,12) DESC, refnumber, begindate DESC"); 
>----- Oorspronkelijk bericht -----
>Van: Richard Yee [mailto:ryee@cruzio.com]
>Verzonden: dinsdag, augustus 7, 2007 01:21 PM
>Aan: user-java@ibatis.apache.org
>Onderwerp: Re: Question using order by
>What did you do to fix the problem?
>davy wrote:
>> It works, really thanks a lot Jeff and Richard!
>> May I ask why the query (order by, substr) did not work when it is written in the
xml file? Is this a bug in DB2, wrong drivers??
>> However I have 1 question, the query works perfectly, but when it displays the information
to the user, my begindate now displays for example (Mon May 14 14:42), in my previous code
(not ibatis) it displays this (2007-05-14 14:42). Now, in my database this is a Timestamp
field, in my code I have written this.
>> RowBeheer[i].setBegindate(String.value(beheer2.getBegindate()));
>> Is this the problem why my timestamp is not correct displayed 
>> (2007-05-14 14:42).

View raw message