Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
I need create variables where i can get the last month and subtract it from the first month where product is "ABC".
So i created one variable like
lastmonth= count({<Month={$(=Max(Month)}>}Patient) and PRODUCT="ABC"
firstmonth=count({<Month={$(=Min(Month)}>}Patient) and PRODUCT="ABC"
final variable=
=num(($(lastmonth)-$(firstmonth))/$(lastmonth),'##0.0%')
please let me know if this is correct as I am getting error?
thanks a lot!
Anuradha
Hi,
Try like this:
lastmonth= count({<Month={'$(=Max({1}Month))'},PRODUCT={'ABC'}>}Patient)
firstmonth=count({<Month={'$(=min({1}Month))'},PRODUCT={'ABC'}>}Patient)
Br,
KC
Hi KC,
I tried it but it showing error in expression ')' expected.
Regards,
Anuradha
Can you try this: or share your expression if it dosent work
(
count({<Month={'$(=Max({1}Month))'},PRODUCT={'ABC'}>}Patient)
-
count({<Month={'$(=min({1}Month))'},PRODUCT={'ABC'}>}Patient)
) /
(
count({<Month={'$(=Max({1}Month))'},PRODUCT={'ABC'}>}Patient)
)