none
Dynamic nested filter in DAX

Answers

  • Hi blezin,

    Thanks for detail description, I try to reproduce your scenario in SQL Server and PowerPivot.

    I create the sample date.


    X table is like the following screenshot.

    Create a calculated column, and calculate the result based on the calculated result.

    Create a measure: 

    result11:=CALCULATE(SUM(DimContent[adj_sentiment_es]),FILTER(DimContent,DimContent[Related-factmonment-identify]="A"))

    If you use T-SQL, it will return 49. Create a pivot table, which only include the measure, it also return 49.

    If you select the content_id as row level, it will show in different rows, the total is 49.

    Best Regards,
    Angelia


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Friday, February 24, 2017 10:11 AM
    Moderator
  • Hi Ben,

    I'm having difficulties to understand your request. Could you please provide sample data (input and desired output) that allows to reproduce which input number goes into which output number (and which not).

    Thx.


    Imke Feldmann
    MVP Data Platform
    TheBIccountant.com

    Monday, April 17, 2017 8:44 AM
    Moderator

All replies

  • Hi blezin,

    In your screenshot, the 1.44534 is sum([sum_adj_sentiment_es]) where the IDs (26425331 and 26430405) for Ginni Rometty. 0.45534 is sum([sum_adj_sentiment_es]) where the IDs (26425331 and 26430405) for IBM. It’s right and dynamic, it will calculate the sum for different category for the IDs (26425331 and 26430405). And the 3.29 is sum([sum_adj_sentiment_es]) for all IDs. You don’t want it, what value do you want?

    Best Regards,
    Angelia

    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.


    Thursday, February 16, 2017 3:21 AM
    Moderator
  • Hi Blezin,

    Thanks for your detail description, please try the formula and check if it works. [measure] means the TOTAL sentiment

    =IF(ISBLANK(Table[sum_adj_sentiment_es]),BLANK(),Table[measure] )

    If you have other issues, please let me know.

    Best Regards,
    Angelia

    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.


    Tuesday, February 21, 2017 9:32 AM
    Moderator
  • Hi blezin,

    Thanks for detail description, I try to reproduce your scenario in SQL Server and PowerPivot.

    I create the sample date.


    X table is like the following screenshot.

    Create a calculated column, and calculate the result based on the calculated result.

    Create a measure: 

    result11:=CALCULATE(SUM(DimContent[adj_sentiment_es]),FILTER(DimContent,DimContent[Related-factmonment-identify]="A"))

    If you use T-SQL, it will return 49. Create a pivot table, which only include the measure, it also return 49.

    If you select the content_id as row level, it will show in different rows, the total is 49.

    Best Regards,
    Angelia


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Friday, February 24, 2017 10:11 AM
    Moderator
  • Hi Ben,

    I'm having difficulties to understand your request. Could you please provide sample data (input and desired output) that allows to reproduce which input number goes into which output number (and which not).

    Thx.


    Imke Feldmann
    MVP Data Platform
    TheBIccountant.com

    Monday, April 17, 2017 8:44 AM
    Moderator
  • Please kindly mark the correct solutions as answers, this could be beneficial to other community members who are facing similar issue. Your contribution is highly appreciated.

    https://social.technet.microsoft.com/wiki/contents/articles/37872.sql-server-installation-on-centos-linux.aspx

    Thursday, January 18, 2018 11:46 AM
    Answerer