Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have the following sum which works:
=Num(sum({<[Year]={$(vCurrentYear)}>}[Hours Worked]*if(IsNull(Rate), 20, Rate)), '£#,##0;(£#,##0)')
What I can't figure out is to add the equivelent of an AND in.
=Num(Sum({<[Year]={$(vCurrentYear)}>} and If(Not([Project Status]='Admin'), [Hours Worked]*if(IsNull(Rate), 20, Rate))), '£#,##0;(£#,##0)')
I was thinking of something like the above, but that just gives a '-' in the result. Any help would be appreciated.
Thanks
Didn't count the '(' and ')' 's. Try:
=Num(Sum({<[Year]={$(vCurrentYear)}, [Project Status] -={'Admin'}>} [Hours Worked]*if(IsNull(Rate), 20, Rate)), '£#,##0;(£#,##0)')
Try:
=Num(Sum({<[Year]={$(vCurrentYear)}, [Project Status] -={'Admin'}>} [Hours Worked]*if(IsNull(Rate), 20, Rate))), '£#,##0;(£#,##0)')
The expression editor doesn't know yet that -= is correct syntax, but that's a bug in the editor so don't worry about the red underlining.
Thanks Gysbert, pasted it in and it's showing '-', so that didn't work unfortunatly.
The editor didn't underlinethe -= , however, it did on the folling {
Didn't count the '(' and ')' 's. Try:
=Num(Sum({<[Year]={$(vCurrentYear)}, [Project Status] -={'Admin'}>} [Hours Worked]*if(IsNull(Rate), 20, Rate)), '£#,##0;(£#,##0)')
Perfect, thank you