September 20, 2011 at 9:49 am
I am trying to write an expression based on two conditions
=sum(Iif(trim(Fields!payrolcd.Value = "SALARY" and (trim(Fields!PAYRCORD.Value) = "SALARY", Fields!Untstopy.Value,0))
This doesn't seem to work. It keeps giving me a syntax error after the comma after the last salary
So if payrolcd= salary and PAYRCORD = salary i want to sum Untstopy
September 20, 2011 at 9:51 am
it look like you are missing the closing ')' for your first TRIM
September 20, 2011 at 9:51 am
Remove the ( before the 2nd trim
September 20, 2011 at 9:54 am
It tells me wrong number of arguments
September 20, 2011 at 9:57 am
=sum(Iif(trim(Fields!payrolcd.Value) = "SALARY" and trim(Fields!PAYRCORD.Value) = "SALARY", Fields!Untstopy.Value,0))
September 20, 2011 at 9:57 am
When I do it like this there are not errors in the expression window but the results are all errors
=sum(Iif(trim(Fields!payrolcd.Value) = "SALARY" and trim(Fields!PAYRCORD.Value) = "SALARY", Fields!Untstopy.Value,0))
September 20, 2011 at 9:57 am
lcarrethers (9/20/2011)
It tells me wrong number of arguments
because the un-partnered brackets are confusing the number of arguments..
September 20, 2011 at 10:00 am
so how should it look
September 20, 2011 at 10:02 am
Ninja's_RGR'us (9/20/2011)
=sum(Iif(trim(Fields!payrolcd.Value) = "SALARY" and trim(Fields!PAYRCORD.Value) = "SALARY", Fields!Untstopy.Value,0))
September 20, 2011 at 10:06 am
That is what i have and all the results are errors?
September 20, 2011 at 10:11 am
lcarrethers (9/20/2011)
That is what i have and all the results are errors?
Then it's a new error because it doesn't show any syntax error in my system.
September 20, 2011 at 10:15 am
In the column the results show
#Error
September 20, 2011 at 10:20 am
In the output window you should have something a little more usefull (yes I know it's annoying!).
September 20, 2011 at 10:29 am
So your telling me
=sum(Iif(trim(Fields!payrolcd.Value) = "SALARY" and trim(Fields!PAYRCORD.Value) = "SALARY", Fields!Untstopy.Value,0))
should work?
How do i trouble shoot that error
September 20, 2011 at 10:32 am
lcarrethers (9/20/2011)
So your telling me=sum(Iif(trim(Fields!payrolcd.Value) = "SALARY" and trim(Fields!PAYRCORD.Value) = "SALARY", Fields!Untstopy.Value,0))
should work?
How do i trouble shoot that error
In the OUTPUT window you'll have the real error. Can't do anything for you without that.
Viewing 15 posts - 1 through 15 (of 36 total)
You must be logged in to reply to this topic. Login to reply