Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi Team,
I need your Precious help on set analysys.
I have two fields called [emp year of hire] and [emp name].
Now i have towrite a set expression to show the sum(sal) for employees whose year of hire is 2010 to 2015 and also have to include sal of employees if anybody having null value as [emp year of hire].
Thanks in advance.
Best Regards,
Nani.
try like this:
if( ([emp year of hire]>=2010 and [emp year of hire]<=2015) or [emp year of hire]=null(),sum(sal))
or
sum({<[emp year of hire]={">='2010'<='2015'"}>}sal)
Hi,
Try this,
sum({<[emp year of hire]={">=2010<=2015"},[emp year of hire]={"=ISNULL([emp year of hire])"}>}Sal)
Regards
Hi avinash,
Thanks for your reply.
My requirement is to incorporate null value condition in set expression.
tried ur expression but it is giving results for only given years not for null values.
Regards,
Nani
Hi Max,
Thanks for your reply...
The expression that u mentioned is returning ' 0' as a result.
Regards,
Nani.
Hi,
Try
Simple if else
try like
sum(if((isnull([emp year of hire]) or len(trim([emp year of hire]))=0) or ([emp year of hire]>=2010 AND [emp year of hire]<=2015),Sal))
Note: Check Bracket if any missing
Regards
Can you try with
Sum({1-< [emp year of hire]={"<2010"} >} Sal)
Try this,
sum({<[emp year of hire]={">='2010'<='2015'"}>}sal) + Sum(If(IsNull([emp year of hire]),sal,0))
Try like this
sum({<[emp year of hire]={">=2010<=2015"}>} if(ISNULL([emp year of hire]),Sal,Sal))