Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi Everyone
This is my table
Name | Status |
---|---|
A | Active |
B | Inactive |
C | Active |
D | Active |
E | Inactive |
I need the result like this
Name | Status |
---|---|
A | Active |
C | Active |
D | Active |
I need to show only active employee.
If you want to do this in front end then try below.
Create a Table chart.
Add dimension as Name
Add expression as MaxString({<Status = {"Active"}>}Status)
If you want to do this in script, try below.
Load Name, Status from xyz where Status = 'Active';
Regards,
Kaushik Solanki
If you want to do this in front end then try below.
Create a Table chart.
Add dimension as Name
Add expression as MaxString({<Status = {"Active"}>}Status)
If you want to do this in script, try below.
Load Name, Status from xyz where Status = 'Active';
Regards,
Kaushik Solanki
Hi Kaushik
I want to do on the front end only.
As you said, I have created a dimension
But when adding to chart, its showing invalid dimension
Why??
You have to ass it as expression(Measure) and not as dimension.
Regards,
Kaushik Solanki
Thank You Kaushik
This is working
After some research I found this is also working
If(Status='Active',Status,Null())
Good to know that you went ahead and found solution by your own..
Keep learning...
Regards,
Kaushik Solanki
It doesn't work. It only adds a dash - where condition is not met. The actual requirement is to show only the rows where condition of one column is met, exactly as shown in Shahzad's question.
This is true - doesnt work
If the table shows only dimensions (without any aggregation) then you can "convert" the Status dimension to measure and use set analysis there:
Only({< Status = {'Active'} >} Status)
And keep the other column(s) as dimensions.
reference: