datesmtd()
4 TopicsDATESBETWEEN or DATESMTD not working
I am struggling to figure out how to get a set of dates for the latest, filtered month of dates in my model. I have two measures which accurately show the range of dates I am looking to run my calculation by, but when I use either of the two functions below, I still get a month's worth of dates in the latest month of my Dates Table: // Option 1 - Dates Between _mtd = DATESBETWEEN(DateTable[Date], [StartOfMonth], [EndOfMonth]) // Option 2 - Dates MTD _mtd = DATESMTD(DateTable[Date]) // Option 3 - Dates MTD with a filtered start _mtd = CALCULATETABLE(DATESMTD(DateTable[Date]), DateTable[Date] = [StartOfMonth]) I'm not sure what I'm doing wrong, but hoping that this is something that's acheivable. I'm ultimately running calculations for current month, month/month, and year/year.Solved1KViews0likes3CommentsCount working days of running month [Friday is weekend only] & Days elapsed
Hi Experts, Please help me out! Struggling to create a measure which will return total working days of current month dynamically [please note, Friday is only weekend in my organization]. I would also want to exclude holidays. I have a calendar table [see scrrenshot], now I want to calculate two measures 1. Total working days of current month 2. Days Elapsed = First Date of current month - Today () -1 [Excluding weekends and holidays] Thans in advance MamunSolved7.8KViews0likes8CommentsDAX formula Day to Day for Year -1
Hi, I need help to get the right formula for my dashboard As you can see on my screenshot, I want to see the MTD from last year. I managed to do it but the total in my table is not the right one. The total is the total of the month, while I would like the total of the month until today's date minus 1 year To obtain the measurement Invoiced Sum YEAR-1 I used the following formula : Invoiced Sum YEAR-1 = CALCULATE([Invoiced_Sum],SAMEPERIODLASTYEAR('Calendar'[Date])) To obtain the measurement Invoiced MTD YEAR -1 I used the following formula : Invoiced MTD YEAR -1 = IF([Invoiced Sum YEAR-1] <> BLANK(), CALCULATE('Main'[Invoiced Sum YEAR-1],DATESMTD('Calendar'[Date])),BLANK()) To obtain the measurement Invoiced MTD YEAR -1 per DAY I used the following formula : Invoiced MTD YEAR -1 per DAY = IF( NOT ISBLANK([Invoiced_Sum]), CALCULATE('Main'[Invoiced Sum YEAR-1],DATESMTD('Calendar'[Date])),BLANK()) Thanks a lot to those who can help me PaulSolved1.8KViews0likes4CommentsDefining Dates for CALCULATE using a parameter and DATESMTD
Metric Current Period = SWITCH('Period Selection'[Period Type Selected], 1, CALCULATE(Transactions[Metric], DATESMTD( { [AsAtDate] }) ) ) Error: Cannot find table ". For the purposes of monthly reporting, I'm trying to define a range of dates to calculate a metric over. The visual will then show a single total for only that period selected. AsAtDate is a measure corresponding to the last day that the report is being made for. I think it's a problem with the way the Column/Single Column Table is being defined? Can I use a Measure in this way?1.1KViews0likes3Comments