Forum Discussion

joangotr's avatar
joangotr
New Member
2 years ago
Solved

How can I display values ​​that do not include an excluded value?

I have a database with project id and sponsor id, if in the visualization I want to show the projects where a specific sponsor does not participate (for example if I have 10 projects and in projects 3 to 7 sponsor 1 participates, in the visualization It only shows me projects 1,8,9 and 10) how can I do this?

Taking into account that in the base I have more than 1,000 projects and 200 sponsors and I want to have the filter for those 200 sponsors

  • Hi joangotr ,

     

    Based on your description, Please try the following steps:
    My Sample:

    1. Please try code as below to Create a Calculated table.

    Table 2 = VALUES('Table'[Sponsor ID])

    2. Use the following code to create two Measures.

    Measure = IF(MAX('Table'[Sponsor ID]) in ALLSELECTED('Table 2'[Sponsor ID]),
                 1,
                 0)
    Measure 2 = SUMX(FILTER(ALLSELECTED('Table'),[Project ID] = MAX('Table'[Project ID])),
                     [Measure])

    3. Select your visual object, put the measure in the “Filters on this visual” section, and filter it by “Measure2 is 0”.

    Result is as below.

     

    Best Regards,
    Yulia Yan

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

2 Replies