ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Andre Peterka" <apete...@nsdcom.de>
Subject Select timestamp from db
Date Mon, 12 Dec 2005 12:26:39 GMT
Hello all

I am having a problem retrieving the current timestamp from the DB (in
this case oracle):

  <select id="getDbDate" resultClass="java.sql.Timestamp">
   select systimestamp from dual
  </select>

I get the follwing error:

--- The error occurred while applying a result map.  
--- Check the getDbDate-AutoResultMap.  
--- Check the result mapping for the 'SYSTIMESTAMP' property.  
--- Cause: java.sql.SQLException: Invalic columntype

Whereas 

  <select id="getDbDate" resultClass="java.util.Date">
   select sysdate from dual
  </select>

Works fine.

Any help is appreciated.

Thanks in advance,
Andre

Mime
View raw message