Hi,
I want to calculate amount for selected quarter and previous quarter using presentation variable.
I have created presentation variable with quarter name and given default quarter is Q2/2024.
Now I want to calculate amount for Q2/2024 and Q1/2024.
I have written formula for default quarter as below .It showing values.
sum(
case(
and(
$CurrType = 'Functional',
parseDate(
gl.fc.QuarterName,
'QQ-YYYY'
) = parseDate(
$v_qtr,
'QQ-YYYY'
)
),
ifNull(
gl.jd.ACCOUNTED_DR,
0.0
) - ifNull(
gl.jd.ACCOUNTED_CR,
0.0
),
0
)
)
i have written formula for previous quarter, but it showing zero values. Please help me how to write formula for pervious Quarter.
sum(
case(
and(
$CurrType = 'Functional',
parseDate(
gl.fc.QuarterName,
'QQ-YYYY'
) = addQuarters(
parseDate(
$v_qtr,
'QQ-YYYY'
),
-1
)
),
ifNull(
gl.jd.ACCOUNTED_DR,
0.0
) - ifNull(
gl.jd.ACCOUNTED_CR,
0.0
),
0
)
)
Thanks.