month
22 TopicsMedian of the Total from Each Month
The current output of my measure is the total count across all months. I want to adjust my measure so that the output is the Median of the total for each month. Current Output: Output = 229 Desired Output: July: 56 August: 56 September: 60 October: 57 Median = 56.5 My measure is exluding November and December, so sometimes the median will be across 4 months, sometimes 5 months, and sometimes 6 months, depending on the time of year. Measure 3 = VAR SelectedDate = SELECTEDVALUE('LOI Date'[Days Until EOM Sort]) VAR CurrentTime = TIME(HOUR(UTCNOW()) - 5, MINUTE(UTCNOW()), SECOND(UTCNOW())) VAR ThresholdTime = TIME(12, 30, 0) VAR TodayDate = TODAY() VAR StartDate = EDATE(TodayDate, -7) -- 7 months back from today RETURN CALCULATE( DISTINCTCOUNT('Opportunity'[Id]), FILTER( 'Opportunity', IF( CurrentTime > ThresholdTime, 'Opportunity'[Days Until EOM] < SelectedDate, 'Opportunity'[Days Until EOM] <= SelectedDate ) && MONTH('Opportunity'[LOI Date]) = MONTH('Opportunity'[Close Date]) && YEAR('Opportunity'[LOI Date]) = YEAR('Opportunity'[Close Date]) && 'Opportunity'[LOI Date] >= StartDate && 'Opportunity'[LOI Date] <= TodayDate && NOT (MONTH('Opportunity'[LOI Date]) IN {11, 12}) -- Exclude Nov and Dec ) )1.6KViews2likes8CommentsCalculate Days in Two Months Based on Start and End Date
EVALUATE VAR StartDate = DATE(2024, 9, 17) VAR EndDate = DATE(2024, 10, 5) -- Find the last day of the start month (September) VAR EndOfStartMonth = EOMONTH(StartDate, 0) -- Calculate the number of days in the start month (September) VAR DaysInStartMonth = DATEDIFF(StartDate, EndOfStartMonth, DAY) + 1 -- Calculate the number of days in the end month (October) VAR StartOfEndMonth = DATE(YEAR(EndDate), MONTH(EndDate), 1) VAR DaysInEndMonth = DATEDIFF(StartOfEndMonth, EndDate, DAY) + 1 -- Return the result RETURN UNION ( ROW ( "Month", FORMAT(MONTH(StartDate), "mmmm", "en-US"), "Days", DaysInStartMonth ), ROW ( "Month", FORMAT(MONTH(EndDate), "mmmm", "en-US"), "Days", DaysInEndMonth ) ) without using format function i get correct month like 09,10 as month. but when i pass month(startDate) to format function returns only January as month. Any why it does that? Month Days January 14 January 5 I want to get Month Days September 14 October 5Solved906Views0likes3CommentsChart showing incorrect month
hi guys , I have a data like below Project Proj Code Creation Date Won Date Lost Date Creation FY Creation FY Month No. Creation Month Won Fy Won Month Won FY Month No. Status Proj1 0001 26 March 2019 18 April 2019 2018-2019 12 March 2019-2020 April 1 Won Proj2 0002 24 September 2019 1 october 2019 2019-2020 6 September 2019-2020 October 7 Won Now to i have to show total projects in different statuses over current fiscal year's months.So below are the measures i have used This year won projects= Var MaxFYYear=MAX('Pipeline Master'[Won FY]) //To give me current fiscal year. Return CALCULATE(DISTINCTCOUNT('Pipeline Master'[Pipeline Code]),FILTER('Pipeline Master','Pipeline Master'[Won FY]=MaxFYYear),'Pipeline Master'[Status (groups)]="Won") Now when i am combining the above measure with "Won Month" column in a chart it shows "March" month too which is not even present in the data.Can you guys please help me why is it happening to me ?Solved1.2KViews0likes1CommentMultiplying Measures by Varied Month Number
I am trying to create a measure to display the following equation: (Annual Target / Months) * (Current Month Number). I have created the following equation and understand that it works correctly, up until the IF function. I have highlighted this in bold. I do not understand my mistake. Live Target = (([TARGET 2024]) / MAX( MonthNumber[Month Number])) * (MONTH(Today()) (MONTH(Today()) IF(_month > 3, _month-3, _month+9))) Key here is that I am trying to vary the current month number so that April is regarded as the 1st month of the year.Solved659Views0likes2CommentsDates (months) out of chronological order on x-axis of chart
Hello, I have a question regarding the order of dates along the x-axis of a chart created in power BI. I am showing the change in a feature for the last 6 months (Sept 2022 - March 2023).. I would prefer to see the most current date as the rightmost value on the x-axis (in the case of a trend in the time series, rearranging these dates has a great influence on the appearance of the line chart); however, Power BI seems to default list the month names in cxhronological order, disregarding the year. If I list the 'year' first, then only the year shows, without division by month. Does anyone know how to place the months in chronological order by year? For reference: the above image shows the x-axis when 'month name' and 'calendar year' are separately defining the x-axis as shown below: When combining the year and month hierarchically, the x-axis looks as follows (disregards the separate months): Any suggestions would be greatly appreciated. Thank you! 🙂485Views0likes1CommentMonth Abbreviation
Hi, in my data I have two fields YEAR and MONTH that I used to create a new column Date = DATE (Data[YEAR],Data[MONTH] ,1) and setting its data type as Date/time I obtain this: which I used to build different graphs., e.g. The problem is that I would use the abbreviated month to save space but I cannot find the way, I tried several approached but none of them worked. Could you help me?Solved7.6KViews0likes7CommentsHow to compare all-time monthly values and output percentage changes ?
Hello Community, I am experiencing difficulty creating a DAX Command that compares my monthly averages and percentage changes. I need to see all-time average rather than the average for the month. I will include the information below. I need to display the % change in a table with the following columns: Product Identification, (All time - 2022-9), (All time - 2022-10), and % change. I do not own the live dataset. Any help would be greatly appreciated. I will provide images below. Thank you! Best,595Views0likes2CommentsLabel month serially from selected periods in DAX
Hello all, I am working with a data set that contains the month in which the customers subscribed for services, and their monthly payment subsequently. The goal is to try and determine the number of customers that dropped off or who didn't make payments on a subsequent basis. I have been able to determine the count of customers on a monthly basis who dropped off. The data looks like this. I have put it in excel to simplify things Monthly Payments Month subscribed Jan-21 Feb-21 Mar-21 Apr-21 May-21 Jun-21 Jul-21 Aug-21 Sep-21 Oct-21 Nov-21 Dec-21 Jan-22 Feb-22 Mar-22 Apr-22 Jan-21 900 867 834 801 768 735 702 669 636 603 570 537 504 471 438 Feb-21 800 767 734 701 668 635 602 569 536 503 470 437 404 371 Mar-21 940 907 874 841 808 775 742 709 676 643 610 577 544 Apr-21 939 906 873 840 807 774 741 708 675 642 609 576 May-21 310 277 244 211 178 145 112 79 46 13 0 Jun-21 893 860 827 794 761 728 695 662 629 596 Jul-21 493 460 427 394 361 328 295 262 229 Aug-21 920 887 854 821 788 755 722 689 Sep-21 120 87 54 21 0 0 0 Oct-21 222 189 156 123 90 57 Nov-21 294 261 228 195 162 Dec-21 748 715 682 649 What I am trying to get at is to normalize the monthly progression of monthly payments relative to the subscription month to look like this; Monthly Payments Month subscribed Month 1 Month 2 Month 3 Month 4 Month 5 Month 6 Month 7 Month 8 Month 9 Month 10 Month 11 Month 12 Month 13 Month 14 Month 15 Month 16 Jan-21 900 867 834 801 768 735 702 669 636 603 570 537 504 471 438 Feb-21 800 767 734 701 668 635 602 569 536 503 470 437 404 371 Mar-21 940 907 874 841 808 775 742 709 676 643 610 577 544 Apr-21 939 906 873 840 807 774 741 708 675 642 609 576 May-21 310 277 244 211 178 145 112 79 46 13 0 Jun-21 893 860 827 794 761 728 695 662 629 596 Jul-21 493 460 427 394 361 328 295 262 229 Aug-21 920 887 854 821 788 755 722 689 Sep-21 120 87 54 21 0 0 0 Oct-21 222 189 156 123 90 57 Nov-21 294 261 228 195 162 Dec-21 748 715 682 649 Please bear in mind that to normalize this, I have to write a DAX to recognize the subscription month as "Month 1" and the subsequent months as "Month 2, Month 3, ..." Please help with this amitchandak Anonymous tamerj1Solved823Views0likes2CommentsHow to add previous month sales to current month sales
Hello all, I'm trying to compare the YTD sales with the goals on YTD format. This is the idea that I want to present: I can make a table adding the goal of each month, which then I can graph as the blue line. The table below: The problem I'm finding is how to add what was sold in Oct (in the image) with Nov, so those sales stack up in Nov, the same with Dec (which should be Oct, Nov and Dec stacked), and so on. The idea of the graph is to show how deviated the sales are resulting against the final goal amount. I tried with TOTALYTD, but it won't add up the months' results. Is there any other function? Or other visualization to achieve this? Thank you.Solved2.7KViews0likes3CommentsPrevious month not working
Hi, If you could please help me out with this error: I have a sales table (with sales of several years back) and the corresponding calendar table. All I need is the count of sales for the previous month. So, I created a measure for the count of sales, like Sales count = COUNTROWS( Sales( SalesID ) ) I created the measure for the sales count previous month, like the following: Sales count PM = CALCULATE( [Sales count], DATEADD( Calendar[Date], -1, MONTH ) ) The result gives me the count of all sales of the table, ignoring the month filter, which is obviously incorrect. Therefore, I experimented with the following alternative formula: CALCULATE( [Sales count], YEAR( Calendar[Date] ) = YEAR( TODAY() ), MONTH( Calendar[Date] ) = MONTH( TODAY() ) -1 ) This time, the result turns out almost correct. But, the month of January does not show any value, because the formula restricts the year to the current year. BTW, I had to filter the year, because otherwise the result sums up the previous month of this year and all previous years too (for example, if the current month is October, the formula would count sales of September this year, and also from previous years). Also, I experimented with the PREVIOUSMONTH function, which always returns a blank result. Am I doing something wrong with the Dateadd function? Thank you and regards.Solved9.9KViews1like2Comments