Hello,
I am trying to figure out how to calculate the difference between two dates, Policy effective and Policy Cancel effective. here is my syntax:
DAYS(UV_QUOTE.POLICY_EFFECTIVE_DATE) -
DAYS(UV_QUOTE.POLICY_CANCEL_EFFECTIVE_DATE)
that should give me the difference between the two points in time. What I am seeing on the report is really strange. It seems to be multiplying this value by 3. No idea why.
Here is the SQL from Webi
SELECT
UV_QUOTE.POLICY_EFFECTIVE_DATE,
UV_QUOTE.POLICY_CANCEL_EFFECTIVE_DATE,
DAYS(UV_QUOTE.POLICY_EFFECTIVE_DATE) -
DAYS(UV_QUOTE.POLICY_CANCEL_EFFECTIVE_DATE)
FROM
(
select * from QHDM.FT_QUOTE_MQT
) AS UV_QUOTE
WITH UR
Nothing exciting there. Is my calculation all wrong? Is there a better way to calculate between in DB2?
[Edited, when posting code samples please use the code option for formatting. It will preserve any indenting or formatting that you may have done. Thank you, Andreas.]
Doolie (BOB member since 2007-08-08)