need help in dax
2 TopicsEarlier function not working well
Hi, I was trying to use Earlier function to get a list of current column value but seems not working well. The DAX is PreviousOccuranceOfWords1 = COUNTX(FILTER(MainQuery, [Start of Month]=MAXX(FILTER('MainQuery', 'MainQuery'[Start of Month] < EARLIER('MainQuery'[Start of Month]) ), [Start of Month])), MainQuery[Value]) There supposes to show the value of count of previous month, but it doesn't. If I change "<" to "<=", then it shows, but it's current month's count. Not sure where is the error.680Views0likes2CommentsSlicer filter not working well on table with mixed columns
Hi, I have a date slicer filter, a table sheet with this date column, two measures related to this date field. The measures have "all" filters with the whole data table. When the date silcer selected "All", there is no issue. When I selecting a date range, I thought the filter should apply to the date column in the table sheet and only show the rows with the date in the range. however, it does not. It only remove some blank rows in the measure and one of the measure is not working if the date is not in the range. The screenshot as below". Is there a way to let the table sheet show correctly after select the date range? Or any solution similar? before select date range: The two measures are: (using Offset to show previous log time if exist and calculate the duration) EachLog_PreviousLogTimestampe = CALCULATE(max('Activity-EachLog-Detail'[LogTimeStamp]),all('Activity-EachLog-Detail'),offset(-1,all('Activity-EachLog-Detail'[Incident],'Activity-EachLog-Detail'[LogTimeStamp]),ORDERBY('Activity-EachLog-Detail'[LogTimeStamp]),KEEP,PARTITIONBY('Activity-EachLog-Detail'[Incident]))) EachLog_Gap_days = DATEDIFF([EachLog_PreviousLogTimestampe],max('Activity-EachLog-Detail'[LogTimeStamp]),HOUR)/24251Views0likes0Comments