Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello
I'm preparing a dimension in the script as follows:
when I use it in a pivot table I'm not getting the descriptions, but the number values
how to display text value of this dimension?
I think this happens when the numeric aspect of your dual field includes nulls. I'd suggest replacing the null with e.g. Dual(Null(),-999) which should then use the text portion.
Try to replace the Null() expression below with Dual(Null(),-999) like suggested
I think this happens when the numeric aspect of your dual field includes nulls. I'd suggest replacing the null with e.g. Dual(Null(),-999) which should then use the text portion.
hello
there are no rows with null values
the if else cover all possible cases
Your screen capture is clearly showing that there is a null, and there's clearly a null() at the end of your outermost if() statement..?
@Or is right, this is due to your NULL value, and more precisely, to the fact that this value is the first one encountered by the script when loading the data.
If you are doing something like this:
testtable:
Load dual('test',1) as test autogenerate 1;
Load null() as test autogenerate 1;
[test] will be displayed with the label.
If you are doing this:
testtable:
Load null() as test autogenerate 1;
Load dual('test',1) as test autogenerate 1;
[test] will be displayed as a number.
So use the trick given by @Or or sort your data.
My expression is something like:
sum(
{
<condition1>
+
<condition2>
}
field
)
condition 1 returns all that do not have values
condition 2 returns all that have values
under condition 2 no records have null for this dimension
And yet your screen capture is clearly showing that the dimension has null values...
yeah but not in the script
but the result of the expression
Sorry, I'm afraid one of us isn't understanding what the other is saying...
If you've tried my suggestion and it didn't work, then perhaps you need to supply more information and/or a sample app demonstrating the issue.
Try to replace the Null() expression below with Dual(Null(),-999) like suggested