db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dmitri Pissarenko" <dmitri.pissare...@gmail.com>
Subject Difference between two timestamp fields
Date Mon, 04 Jun 2007 19:18:11 GMT
Hello!

I need to calculate the difference between two timestamp fields in
seconds. I tried this query:

SELECT APP.MyTable.startTime, {fn TIMESTAMPDIFF(SQL_TSI_FRAC_SECOND,
APP.MyTable.startTime, APP.MyTable.endTime)}
FROM APP.MyTable
WHERE APP.MyTable IS NOT NULL

but it doesn't work, I'm getting the error

SQL State = 42Y07 SQL Code = 30000 SQL Message = Schema 'SYSTEM' does
not exist Exception message = java.sql.SQLSyntaxErrorException: Schema
'SYSTEM' does not exist


How can I calculate the difference between two timestamp fields?

TIA

Dmitri Pissarenko
-- 
http://www.xing.com/profile/Dmitri_Pissarenko
http://dapissarenko.blogspot.com/

Mime
View raw message