jvm update breaks timestamp compare?


i have code determines if form status needs change based on how old add date form is. worked fine until jvm upgraded java 5 (jvm 1.5.0_06). classcastexception on attached code (see bottom).

cf error message:
error casting object of type java.sql.date incompatible type. indicates programming error in java, although mean have tried use foreign object in different way designed. java.sql.date

stack trace:
java.lang.classcastexception: java.sql.date
@ java.sql.timestamp.compareto(timestamp.java:474)
@ coldfusion.sql.imq.rttexprcomparator.datecompare(rttexprcomparator.java:81)
@ coldfusion.sql.imq.rttexprcomparator.stringordatecompare(rttexprcomparator.java:184)
@ coldfusion.sql.imq.rttexprcomparator.genericcompare(rttexprcomparator.java:429)
@ coldfusion.sql.imq.rttexprcomparator.compare(rttexprcomparator.java:454)
@ coldfusion.sql.imq.rttexprcondcomp.evaluate(rttexprcondcomp.java:120)
@ coldfusion.sql.imq.rttexprcondtest.evaluate(rttexprcond.java:273)
@ coldfusion.sql.imq.rttexprcondand.evaluate(rttexprcond.java:145)
@ coldfusion.sql.imq.rttexprcondand.evaluate(rttexprcond.java:145)
@ coldfusion.sql.imq.rttselectexprspec.evaluatewhere(rttselectexprspec.java:245)
@ coldfusion.sql.imq.rttselectexprspec.evaluate(rttselectexprspec.java:184)
@ coldfusion.sql.imq.rttselectstmt.evaluate(rttselectstmt.java:61)
@ coldfusion.sql.imq.jdbcstatement.fetchresult(jdbcstatement.java:539)
@ coldfusion.sql.imq.jdbcstatement.execute(jdbcstatement.java:131)
@ coldfusion.sql.executive.executequery(executive.java:719)
@ coldfusion.sql.sqlimpl.execute(sqlimpl.java:240)
@ coldfusion.tagext.sql.querytag.doendtag(querytag.java:499)
@ cftest22ecfm294473356.runpage(c:\cfusionmx7\wwwroot\pdftest\fixsqlforitp\test2.cfm:17)

(there's more don't think it's relevant... think first couple of lines important).

it appears coldfusion calling java.sql.timestamp.compare(object o) function , passing in java.sql.date object. according java api specs of java 1.5 java.sql.date.compare(date o) function overriden in java.sql.timestamp , requires parameter timestamp object or... guessed it, throw classcastexception.

this appears limited query of queries.

how can force coldfusion pass timestamp instead of date object?! bug or feature? updated cfserver version 7,0,1,116466, figuring if it's bug have reported it. totally misunderstanding it's telling me? there way around short of me looping through each row of "parent query" (allrecs)?

coldfusion isn't certified run on jvm 1.5.


More discussions in ColdFusion


adobe

Comments

Popular posts from this blog

Convierte tu Raspberry en un NAS. Firmware fvdw-sl 15.3 - Raspberry Pi Forums

How to format a Get Request

avrdude: verification error, first mismatch at byte 0x0000 0x0c != 0x62