Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
=Alt( WildMatch( GetFieldSelections(%Dimensions, '|'), '*Country*') ,0 |
Consider that you have below in your script...
Dimensions:
Load * Inline
[
%Dimensions
Customer
Country
Sales
Purchase
];
Now considering that you have a list box %Dimension
Let me break this expression so better to understand.......
GetFieldSelections(%Dimensions, '|')
The above expression will give you List of All selected values from List box %Dimension
Consider that you have selected Country and Customers, it will give you result as below
Country|Customer
WildMatch(GetFieldSelections(%Dimensions, '|'),'*Country*')
WIldMatch will check that from the selected values of %Dimension, is there any values named Country or not?
For above example, where we have result Country|Customer it will give you 1 but it there is not Country selected, it will give you 0 due to you have used Alt (Expression, 0)
For further understanding, kindly refer to QlikView Reference Manual and check WildMatch, Alt and GetFieldSelection functions...
Hi,
If selected '%Dimensions' contains '*Country*' then '%Dimensions'
else 0
Hope this helps.
Andrei
Consider that you have below in your script...
Dimensions:
Load * Inline
[
%Dimensions
Customer
Country
Sales
Purchase
];
Now considering that you have a list box %Dimension
Let me break this expression so better to understand.......
GetFieldSelections(%Dimensions, '|')
The above expression will give you List of All selected values from List box %Dimension
Consider that you have selected Country and Customers, it will give you result as below
Country|Customer
WildMatch(GetFieldSelections(%Dimensions, '|'),'*Country*')
WIldMatch will check that from the selected values of %Dimension, is there any values named Country or not?
For above example, where we have result Country|Customer it will give you 1 but it there is not Country selected, it will give you 0 due to you have used Alt (Expression, 0)
For further understanding, kindly refer to QlikView Reference Manual and check WildMatch, Alt and GetFieldSelection functions...