Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
LucaixBolha
Resolver I
Resolver I

How to do a new column with string values that come from different segmentations on the same data

Hello! 

 

I have a database going under three different types of segmentation (via slicer/buttons): 

1) The rank selectors on green that I can choose or not to be applied;
2) The pink "Top N" slicer, which allows me to restrain the number of Asset Codes displayed at each one of the four white visuals on the top of the page;
3) The four orange slicers that allow me to restrain values if I want to (what also automatically rearrange the ranks at the four white visuals).

My goal is to generate dynamically (after I choose whichever selections at any or all of the 3 segmentation levels) a table/column/slicer/anything that shows me the Assets Code contained in all white visuals, gathered in one place, just like the table in the blue visual (I applied a filter level to build an example of the final result).

LucaixBolha_0-1658330987130.png

 

Here is the file of the pbix: https://drive.google.com/file/d/1N_g1fl5zkXibp6vNwy9s_oBifJCiGu0n/view?usp=sharing

Does anyone have a clue how to solve this issue?
Tks! 🙏

  

1 ACCEPTED SOLUTION

I got the idea! Thanks @lbendlin , Ill try to make it work! 🙏

View solution in original post

6 REPLIES 6
lbendlin
Super User
Super User

Your example uses a combination of filters ( AND ).

lbendlin_0-1658543596723.png

By coincidence it matches the values in the other tables, but what you actually want to achieve is a collection of independent results ( OR ).  You can only do that with a measure that tests for 

 

[Market Value] > 0 || [Negotiation Volume] > 0 || [P/BV]> 0 || [Volatility] > 0

 

The ||  is what DAX uses for " OR " .

Hi @lbendlin , thanks for your answer! Ahh these filters were "leftovers" from an earlier attempt of mine, in fact the reason why it matches exactly the values in the other tables is because I've filtered the Asset List in order to show the selected values, here:

LucaixBolha_0-1658707927372.png


Using your description, my goal would be an (AND) filter type, like if I told Power Bi to do this:

"Give me a column that aggregates dynamically the names of the Assets filtered by:
           - the P/BV ranking (AND);
           - the ones filtered by the Market Value ranking (AND)
           - the ones filtered by the Negotiation Volume ranking (AND)
           - the ones filtered by the Volatility ranking

I just have no ideia how it could be done with DAX 😅

Let me repeat - what you need is an OR filter, not an AND filter.

Hmm I see 🤔 ...I understand the idea of a collection of independent results, but when I tried it showed me this: 

LucaixBolha_0-1658750564222.png

TTEN3 is the only Asset Code that appears because it is the only one that is within the range established by the four orange slicers. Were you picturing something like this (a calculate measure, applying the filters as you've mentioned)?
 

Yes, that requires a measure which you then use as a filter on the visual

I got the idea! Thanks @lbendlin , Ill try to make it work! 🙏

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.