Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi, I have the following problem:
My table looks like this
KEY NAME PRODUCT OLD_ID NEW_ID OLD_COUNTRY NEW_COUNTRY
1 AAA FFF 2 3 IT IT
2 BBB GGG 4 5 USA FR
3 DDD HHH 6 7 GB ES
I would like to see the row blank if the old data is different than the new data:
KEY NAME PRODUCT OLD_ID NEW_ID OLD_COUNTRY NEW_COUNTRY
1 AAA FFF 2 3
2 BBB GGG 4 5 USA FR
3 DDD HHH 6 7 GB ES
I'm using the "show column if" in the column of the table like this (ignore the red, it's an example):
but I still see the data also if they are the same (already trimmed, same type...)
What can I do?
You probably are trying to hide the VALUEs of the columns rather than the COLUMN itself. Try using the measure itself instead of 'show column if' condition.
Hi, I'm trying to hide the values of the columns if there are no differences, but also hide the columns if there are no differences at all in any rows
I added a calculated column if(old=New, 'The same','Different') and as you can see they are the same in every row... but the "show column if" with "old<>new" is still not working
Try a condition like:
=Not Max(OLD=NEW)
Thank you, but this columns contains strings, not numbers, there are also values like "F38Z2"
there are few methods to achieve this, easiest ones are:
//1. if backend code can be used:
Data:
Load * Inline [
KEY,NAME,PRODUCT,OLD_ID,NEW_ID,OLD_COUNTRY,NEW_COUNTRY
1,AAA,FFF,2,3,IT, IT
2,BBB,GGG,4,5,USA,FR
3,DDD,HHH,6,7,GB,ES
];
Qualify *;
d:
Load KEY,NAME,PRODUCT,OLD_ID,NEW_ID,
if(OLD_COUNTRY=NEW_COUNTRY, OLD_COUNTRY) as OLD_COUNTRY,
if(OLD_COUNTRY=NEW_COUNTRY, NEW_COUNTRY) as NEW_COUNTRY
resident Data;
//2. if front end code can be used:
Dims: KEY,NAME,PRODUCT,OLD_ID,NEW_ID
Measures:
Measure1 = if(OLD_COUNTRY=NEW_COUNTRY, OLD_COUNTRY)
Measure2 = if(OLD_COUNTRY=NEW_COUNTRY, NEW_COUNTRY)
Yeah ok I tried the measures, but if the OLD column and NEW columns have ALL THE VALUES EQUALS, I want to hide these columns.
IF I have a table like this:
ID OLD1 NEW1 OLD2 NEW2
1 1 1 aa aa
2 4 5 bb bb
3 6 7 cc cc
the output should be:
ID OLD1 NEW1
1
2 4 5
3 6 7
you mentioned: I would like to see the row blank if the old data is different than the new data