Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Dear All,
How can we filter specific rows by using function and without changing the load script? Let us assume I have a table with one column
EmpID
1025
1028
1029
1038
1054
Now I wanted to filter only 1028 and 1054 records by using a function. I am sure this is fairly simple...
If possible, please provide 2 functions - one regular function and another one with set analysis.
TIA!
Cheers - DV
Yeah, sorry, very unclear what you want.
But let's say you want sum(Sales), but only for those two specific EmpIDs, and always just those two. You can use set analysis:
sum({<EmpID={'1028','1054'}>} Sales)
You also mention a "regular function", by which you might mean this:
sum(if(match(EmpID,1028,1054),Sales))
Or maybe you only want those two values as a dimension on some table. You could use a calculated dimension:
if(match(EmpID,1028,1054),EmpID)
But as long as you're hardcoding IDs, you could put it in the script for even better chart performance when using it as a dimension:
,if(match(EmpID,1028,1054),EmpID) as SpecialEmpID
Dimension = SpecialEmpID
And so on with various other answers depending on your actual requirement, which I really don't know.
Any suggestions please...?
This sort of filtering is usually done by maikng selections.
Maybe you have something else in mind, but it is not clear from your question...
Yeah, sorry, very unclear what you want.
But let's say you want sum(Sales), but only for those two specific EmpIDs, and always just those two. You can use set analysis:
sum({<EmpID={'1028','1054'}>} Sales)
You also mention a "regular function", by which you might mean this:
sum(if(match(EmpID,1028,1054),Sales))
Or maybe you only want those two values as a dimension on some table. You could use a calculated dimension:
if(match(EmpID,1028,1054),EmpID)
But as long as you're hardcoding IDs, you could put it in the script for even better chart performance when using it as a dimension:
,if(match(EmpID,1028,1054),EmpID) as SpecialEmpID
Dimension = SpecialEmpID
And so on with various other answers depending on your actual requirement, which I really don't know.
This is perfect! Thanks so much for your help....
I have a similar issue...I have a table box with all the info in it. From that i created a second chart (a straight table) using the info from the Table Box. All i want in my straight table are the rows associated with Order Status 66.
I tryed the calculated dimension you showed here and thats not working for me, it creates a new column...
Can you help me?
Thansk
Karen