+ Reply to Thread
Results 1 to 2 of 2

Prevent DAX measure from calculating subtotals

  1. #1
    Registered User
    Join Date
    09-07-2018
    Location
    Stockholm
    MS-Off Ver
    Latest
    Posts
    1

    Prevent DAX measure from calculating subtotals

    Hello

    I have a pivot-table with added DAX-measures in powerpivot.

    I want to show the increases and decreases in a value on a project level versus same month prior year in two separate columns.

    To do this I use the dateadd function and an if-statement that only shows increases (SUM>0) in one column and decreases (SUM<0) in another.

    The problem I encounter is that the DAX formula also calculates the subtotal sums as >0 and <0 on an aggregate level. If the subtotal is >0 then it does not show the sum of values that ar <0. Below table illustrates this.

    example2.PNG

    The formula i use for the measures are:

    Please Login or Register  to view this content.
    Please Login or Register  to view this content.
    Please Login or Register  to view this content.
    I've tried using COUNTROWS/HASONEVALUE to no avail. Also filtering and SUMX.

    I cannot seem to get it right. Is there anyone out there who has encountered this issue before?

    Best Regards
    Stefan

  2. #2
    Forum Expert rorya's Avatar
    Join Date
    08-13-2008
    Location
    East Sussex, UK
    MS-Off Ver
    2016 primarily
    Posts
    6,058

    Re: Prevent DAX measure from calculating subtotals

    I think you'll probably want a combination of SUMX and SUMMARIZE to effectively create a table of the results that you can simply sum for the subtotals. It would be easier to help with a sample workbook though.
    Rory
    I drink, and I know things

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Calculating Subtotals
    By Citylemon in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 01-29-2014, 12:36 PM
  2. [SOLVED] Calculating subtotals for consultants
    By jonbennett84 in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 01-02-2013, 09:44 AM
  3. Calculating an average for row label subtotals
    By mtflores_2000 in forum Excel Charting & Pivots
    Replies: 0
    Last Post: 10-12-2012, 02:25 PM
  4. Excel 2007 : Calculating subtotals in pivot table
    By holmes123 in forum Excel General
    Replies: 0
    Last Post: 08-08-2011, 10:00 AM
  5. Calculating Subtotals for Different Categories
    By DerStro in forum Excel General
    Replies: 3
    Last Post: 05-12-2011, 12:08 PM
  6. calculating total time worked to measure SLA
    By billsoule in forum Excel General
    Replies: 4
    Last Post: 12-01-2010, 05:49 PM
  7. lock Subtotals to prevent overwriting.
    By gruf1968 in forum Excel General
    Replies: 1
    Last Post: 03-12-2010, 07:01 PM
  8. Calculating Weighted Average on Subtotals
    By Cjax in forum Excel General
    Replies: 1
    Last Post: 07-23-2009, 08:59 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1