Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I've below data.
ID | New | Value |
1 | abc | 123 |
1 | abc | 456 |
1 | abc | 789 |
2 | efg | 963 |
I'm using the below IF statement to show the three values if I select 'abc' but it is showing only value '123'
if(match(ID,'1') and match(New'abc'),'123',if(match(ID,'1') and match(New,'abc'),'456' ,
if(match(ID,'1') and match(New'abc'),'789')))
I'm looking for an IF Statement to show all the three values if I select 'abc'.
Regards,
Vikas
Try this
IF(Match(ID,'1') and WildMatch(New,'*abc*'),Value,Null()) as [abc Values]
Where are you applying this expression and what is your expected result regarding those three values given that a single expression only returns a single value per evaluation?
I'm trying to apply this in the load script, my expected result is if user select abc the result should be three values associated to abc (123, 456, 789)
Tried this but not giving the expected result.
Hi @vikasshana
I can assure you that the syntax works perfectly. And because it's conditioned selecting the value abc won't alter the output values.
LOAD *,IF(Match(ID,'1') AND WildMatch(New,'*abc*'),Value,Null()) as [abc Values];
LOAD * Inline[
ID,New,Value
1,abc,123
1,abc,456
1,abc,789
2,efg,963
];
O/P