8 Replies Latest reply: Jan 15, 2014 1:27 PM by Simon Brulotte

# Is not equal to...

Hi,

here is a simple dimension definition in a straight table:

= if(FABS(%CR003M)<>1,[Poste budgétaire])

It's suppose to see if the absolute value of %CR003M is not equal to 1, and bring back the culprit Poste Budgétaire.

FABS(%CR003M) = 1 works well, but not the <> .

What could I be doing wrong? This sounded so simple to me...

• ###### Re: Is not equal to...

Hi,

I think <> should be working, however if you have problems with that operator, you may try with Not:

= if(NOT FABS(%CR003M)=1,[Poste budgétaire])

regards

• ###### Re: Is not equal to...

I believe I have seen in some instances -= being used, however I am not sure this works 100% of the time. Ideally the <> should work.

• ###### Re: Is not equal to...

I think -=, +=, *=, etc just work when you're using Set Analysis. In this case, <> or Not should work,

regards

• ###### Re: Is not equal to...

Hey Simon,

As others mentioned <> should work fine. What kinda data does %CR003M hold. Can you post some sample data. Is it showing error or is it not giving the dimensions you are looking for when using <>?

Thanks

AJ

• ###### Re: Is not equal to...

I expect it to work...  Anyway, if "<>" doesn't work but "=" works, here is another version:

= if(FABS(%CR003M)=1,null(),[Poste budgétaire])

• ###### Re: Re: Is not equal to...

Hi,

thanks for the many responses, all of which were tried without success.

So there should only be values of 1, or -1, and the control is to avoid having 0, or other erronous multipliers in the table.

I've attached a table that shows I have values for %CR003M that are 0 for a few Poste Budgétaire.

The load showing that there is no modifier to text the value.

The format in the excel file that is loaded is set to standard.

I've tried also

=

if(sum(FABS(%CR003M))<>1,[Poste budgétaire])

and also tried

=

if(sum(FABS(%CR003M))=1,Null(),[Poste budgétaire])

I'm still getting an empty straight table table.

• ###### Re: Re: Re: Is not equal to...

Please check out the attached file. It uses the exact formula for the calculated dimension thats been mentioned and it works.

• ###### Re: Is not equal to...

Hi,

thanks for the many responses

The problem was not with the dimension definition but with my expression.

I was trying to show the value of the field %CR003M, which is 0, and thus does not return a line since it's a straight table summing.. zero.

So yeah, like Ajay was doing in the file was just a count of the %CR003M. To make it work, I actually had to have it past the FABS test prior to counting though. So partial points Ajay, but not a green star

Also, Ajay, the test was <> 1, not <>0.