dax

  1. D

    Using iterators where there are duplicate values

    Hi, I've been doing a bit of experimenting, so I have a simple measure ; SUM(Tsales [Units] ) Whichi I have then wrapped in a AVERAGEX and SUMX , its only a two column table Item and unit and I made sure I had duplicate values, which as it's tiny it is easy to see how the duplicates are...
  2. D

    DAX calendar in pbi

    Is there a way of putting the date column into a matrix that is not a hierarchy, I can do this using the date column from the fact table, but would prefer to use calendar table as I've gone to the trouble of making it, essentially the left , which uses the calendar table to look a bit more like...
  3. D

    DAX running total column using ALLEXCEP and ALL and VALUES

    Hi My question relates to the use of multiple CALCUALTE / CALCULATETBALE. I've been using ALLEXCEPT to create a running total column by a certain criteria , customer or whatever, so EXCEPT that criteiria, but wanted to use ALL and VALUES, to see how it worked, The formula I used was VAR...
  4. D

    DAX studio and running total

    Hi, I have a calculated column , power pivot , returning a running total , (dex = index) EVALUATE VAR CurrentRow = SaleT[dex] VAR CurrentItem = SaleT[item] VAR filteredtable = FILTER ( ALL ( SaleT ), SaleT[dex] <= CurrentRow && SaleT[item] = CurrentItem ) RETURN CALCULATE ( SUM (...
  5. D

    DAX running total using 'Calendar' table that respects filter context,

    I hope I've got my row / filer the the right way round, I created two measures one using the dates from the fact table the other from the calendar table RTM using C = VAR mcdate = MAX('Calendar'[Date]) VAR anser = CALCULATE([Tsales],FILTER(ALL('Calendar'[Date]),'Calendar'[Date]<= mcdate))...
  6. D

    ALLEXCEPT versus ALL and VALUES

    Hello, I've been experimenting with ALLEXCEPT and ALL and VALUES, and aren't quite sure what's happening, with 'excpept' it seems to see the entire data model and return the overall total regardless of the current filter context but with VALUES, the total is in the current filter context and...
  7. D

    DAX running total that does not recalculate at the end of a period or group.

    HI, I have a simple running total measure ; RTM:=VAR mdate = MAX(Table2[Date]) VAR anser = CALCULATE([tSales],FILTER(ALL(Table2[Date]),Table2[Date]<= mdate ) ) RETURN anser but when I put this into a pivot table where the dates are groped by Month the accumulative pricess restarts at the...
  8. D

    Total iterating over dimension table

    Hi, I have set up two simple tables, "tsales" ; Product , Sales , Discount applied, and 'Product' consisting of Product , Price, so revenue would be tsalesA:=SUMX(Tsales,Tsales[Sales]*(1-Tsales[Sales Discount])*RELATED('Product'[Price])) ignoring the discount and iterating over the...
  9. J

    DateDiff not working the same in excel as it is Powerbi

    Hi, In PowerBI I have a measure with DaysPastDueDate = DATEDIFF (AUDIT_HEADER[DUE_DATE], TODAY (),DAY) That doesnt seem to work in Excel PowerPivot and it requires it to be a calculated column. If I make the column witrh that calculation it doesnt seem to like it when the start date is...
  10. D

    AVERAGEX iterating over one table with calculation on another

    Sorry for a poor description, essentially in the scenario the granularity of an average was changed by iterating over the linked date table; So to start you have ; Average M:=AVERAGEX(fTransactions,[Total Revenue Iterate Over Fact]) Fine, but do change the granularity this then becomes...
  11. D

    DAX studio

    Hi, Is it possible to use DAX studio without a connected data source, I ask this because I was using it to build a date table from scratch which I then put into excel using a 'existing connections' and pasting the code in., so the fact that a data source was connected it wasn't needed. Richard.
  12. D

    DAX nth largest value

    Hi, Is there a way of getting the nth largest value using DAX, something like LARGE in excel or list.firstN ( list, count ) {x} ? Richard
  13. arnabmit

    Sum of bottom 20% values

    I was trying to get the sum of the bottom 20% values, then show it by year. However, the DAX returned the total value. Bottom 20% Values = VAR BV = ROUND(COUNTROWS(Sheet1) * 0.2,0) VAR DR = RANKX(ALL(Sheet1),CALCULATE(SUM(Sheet1[Value])),,DESC,Skip) RETURN IF(DR <= BV...
  14. D

    DAX Keepfilters on two tables,

    Hello, I'd like to run to filter my result by two tables but using keepfilter so the external filter context is kept, < EVALUATE...
  15. P

    Generate only a needed number of rows in DAX

    Hi guys! We are woking with big documents ( ~ 20 pages), however for a visualization we need to analyze them by sentences. We have a code for break-down, however the first step for that is that we need a calculated table which generates X number of rows. We have performance issues with this...
  16. D

    SUMX iterate over smaller table using VALUES

    Hello, just to note I meant to put VALUES not RELATED in the title, but posted and edit won't let me change it. (edit: changed for you :)) Just a question regarding what's actually happening,; I have a formula ; Over...
  17. D

    DAX filter on two tables

    Hi, I'd like t filter by two tables, very simply I have : Green and 10+ :=CALCULATE([Total Units]...
  18. D

    DAX Direct Query

    Hello, I have a question regarding some DAX functions, What exactly does This function is not supported for use in DirectQuery mode when used in calculated columns or row-level security (RLS) rules. mean? I presume the function has to be nested...
  19. D

    DAX Rolling 7 day total

    Hi, I'm trying to do a 7 day rolling total in DAX, I've followed a similar structure to what I'd do in excel, in excel I wouldn't have the first condition, just greater than; < moving := VAR abc = MAX(Table1[Date])...
  20. S

    DAX query - Looking up (v-lookup) in the same table

    Hi All, Hoping can get some input from the DAX experts here. I have a table imported via power query. It has 2 columns Employee ID - this contains a list of employee IDs Month - this contains 'current month' and 'last month' value Note - The same employee ID can appear twice in the table...

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top