Try TIMESTAMP. Clinton
On Fri, 14 Jan 2005 08:23:05 -0600, Brice Ruth <[EMAIL PROTECTED]> wrote: > That's bizarre ... off the top of my head, you could use a <dynamic> > clause to catch if its null and try setting last_exported_date=NULL > explicitly. See if the MS SQL driver likes that any better. > > On Thu, 13 Jan 2005 17:32:32 -0600, Barnett, Brian W. > <[EMAIL PROTECTED]> wrote: > > The use of this update statement throws an error when lastExportedDate is > > null. (lastExportedDate is java.util.Date) Works fine if it's not null. I > > tried using DATE instead of DATETIME, but then the time would not get > > written to the db. > > > > <update id="updateConfig" parameterClass="config"> > > UPDATE config SET > > last_exported_date=#lastExportedDate:DATETIME# > > WHERE config_id = 1 > > </update> > > > > This is the error: > > com.ibatis.dao.client.DaoException: Error executing update. Cause: > > com.ibatis.common.jdbc.exception.NestedSQLException: > > --- The error occurred in com/scholar/model/map/ConfigSQL.xml. > > --- The error occurred while applying a parameter map. > > --- Check the updateConfig-InlineParameterMap. > > --- Check the parameter mapping for the 'lastExportedDate' property. > > --- Cause: java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for > > JDBC]The specified SQL type is not supported by this driver. > > > > Any suggestions on how I can resolve this? > > >

