BusinessObjects Board

Variable not showing when null

Hey, so i have a variable that goes something like this:
=If([Var]<=0;“0”;(If([Var] =1;“1”;(If([Var]=2;“2”)
This works great but when a [Var] doesn’t equal a number it doesn’t show up in the results so in the end i only see numbers where there is data. This is quite unprofesional. Any help would be great. thanks.


showt2 (BOB member since 2009-05-11)

Hi,

Have you tried modifying the formula this way?

=If([Var]<=0;"0";(If([Var] =1;"1";(If([Var]=2;"2";"something else") 

Marek Chladny :slovakia: (BOB member since 2003-11-27)

thanks for the reply. but basically my variable reaches all the way to 10 i limited it earlier to only show 2. but say if there is values for 0 and 2 it will now show 1 at all and only show:
0
2
I need it to show all numbers:
0
1
2
Please help. :hb:


showt2 (BOB member since 2009-05-11)

What do you want it to display if the value is not 0-10?

Joe


joepeters :us: (BOB member since 2002-08-29)

it should just say ‘>10’


showt2 (BOB member since 2009-05-11)

Have a look at this Reporter’s FAQ:


Marek Chladny :slovakia: (BOB member since 2003-11-27)

If i understnad you correctly, you may want to click on the block and go to “Properties” tab and check “Show rows with empty dimension values”.


Abishek :us: (BOB member since 2004-12-09)

hey Abishek, i’ve tried that as well, but it doesn’t show still.


showt2 (BOB member since 2009-05-11)

is your variable measure or dim? if measure did you try checking “Show rows with empty measure values”.


Abishek :us: (BOB member since 2004-12-09)

Then a slight variation of Marek’s code should work:

=If ([Var] Between (0;10);FormatNumber([Var];"0");">10") 

Joe


joepeters :us: (BOB member since 2002-08-29)