Forum Discussion

Alltasks_Chris's avatar
Alltasks_Chris
Frequent Visitor
4 years ago
Solved

Visualise a List or Column style result

Can anyone tell me what this means: 

 

I'm trying to see if a measure I made even works but I can't figure out how to visualize it - here's my measure:

 

ThisWeekDays =
            
            VAR TodayNo = WEEKDAY(TODAY(), 3)
            VAR StartOfWeek = TODAY() - TodayNo
            VAR weekdays = DATESBETWEEN('Calendar'[Date], StartOfWeek, TODAY())
            
            RETURN weekdays
 
I'm hoping it returns something like [0] if it's Monday, [0, 1] if it's Tuesday, [0, 1, 2, 3, 4] if it's Friday...etc

5 Replies

  • I think that you should use MAX function

    ThisWeekDays =
                
                VAR TodayNo = WEEKDAY(TODAY(), 3)
                VAR StartOfWeek = TODAY() - TodayNo
                VAR weekdays = DATESBETWEEN(MAX('Calendar'[Date]), StartOfWeek, TODAY())
                
                RETURN weekdays
  • There are no logic errors in my Measure but it returns a table with multiple values instead of one and that's my intention, the end goal I'm going for won't actually use this measure at the moment I'm just trying to physically see the results of my above DAX to ensure it's getting the results I think it should be.

      • Alltasks_Chris's avatar
        Alltasks_Chris
        Frequent Visitor

        Thankyou, that's exactly what I needed. My DAX isn't doing what I thought it was but this is how I could see what it is doing to continue to troubleshoot - thankyou!