+ Reply to Thread
Results 1 to 1 of 1

DAX Power Pivot return last date

Hybrid View

  1. #1
    Forum Contributor
    Join Date
    08-03-2021
    Location
    London
    MS-Off Ver
    365
    Posts
    777

    DAX Power Pivot return last date

    I'm getting the wrong dtate returned when trying use a measure to bring back the date prvious to the 'current date,


    Filtered Table using max:=VAR MdateL = MAX(LastT[Date]) 
    RETURN 
    MAXX(
    FILTER(ALL(LastT[Date]),LastT[Date] < MdateL  ), LastT[Date])
    Filtered Using If has one:=MAXX( 
    FILTER(ALL(LastT[Date]),LastT[Date] <  IF(HASONEVALUE(LastT[Date]),VALUES(LastT[Date]) ) ),LastT[Date])

    So if the current date is 07/01/2020 and the previous 01/01/2020 so if in Rows I have 07/01/2020 values 01/01/2020

    but it keeps adding one so I have 02/01/2020, im pretty certain the formula is ok so can't see whats causing it, i've checked data types,

    please help.

    Workbook attached,

    Richard
    Attached Files Attached Files

+ 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. Replies: 1
    Last Post: 10-06-2022, 11:11 PM
  2. Grouping Date in Power Pivot
    By piku9290dgp in forum Excel General
    Replies: 1
    Last Post: 06-10-2021, 01:53 AM
  3. Replies: 1
    Last Post: 01-09-2021, 06:14 AM
  4. Pivot / Power Pivot - Year To Date Column
    By Ballet4ever in forum Excel Charting & Pivots
    Replies: 12
    Last Post: 04-30-2019, 08:42 AM
  5. Sub-Forum for Excel Power Tools (Power Query, Power Pivot & Power BI)
    By chullan88 in forum Suggestions for Improvement
    Replies: 10
    Last Post: 06-28-2018, 02:25 PM
  6. Date fields in power pivot
    By stephme55 in forum Excel General
    Replies: 1
    Last Post: 09-03-2016, 01:34 AM
  7. Date formats in pivot tables using power pivot in Excel 2010.
    By myobreportguru in forum Excel Charting & Pivots
    Replies: 0
    Last Post: 03-25-2013, 10:21 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