hi can anyone tell me how to find time diffe in minutes from timestamp...
i tried below sql queries but this is not retrieving correct diff in minutes
SELECT TRUNC((86400*(CURRENT TIMESTAMP - ('2011-06-18-05.03.41.300585')))/60)
-60*(TRUNC(((86400*(CURRENT TIMESTAMP - ('2011-06-18-05.03.41.300585')))/60)
/60))
FROM SYSIBM.SYSDUMMY1
SELECT MINUTE(CURRENT TIMESTAMP) - MINUTE('2011-06-15-02.01.56.178837')
FROM SYSIBM.SYSDUMMY1
05 WS-TIME-DIFF PIC X(04).
05 BDR-BKT-REQ-TIMESTMP PIC X(26) VALUE '2011-06-15-02.01.56.178837' .
EXEC SQL
SET :WS-TIME-DIFF = MINUTE(CURRENT TIMESTAMP) - MINUTE(BDR-BKT-REQ-TIMESTMP)
END-EXEC
SO IF ANYONE KNEW TO FIND TIME DIFFERENCE FROM TIMESTAMP IN MINUTES ...PLS TELL ME AS SOON AS POSSIBLE...ITS URGENT