Forum Discussion

sccoleman1189's avatar
7 years ago
Solved

Show data past current date and approaching current date

Hello,   This may be a basic question but I need help creating 2 tables:   1. Table that shows data past current date (expired orders).   Ex. Current date 11/01/2020 Need Date         Order Nu...
  • v-eachen-msft's avatar
    6 years ago

    Hi sccoleman1189 ,

     

    I think you want to create two new tables from the raw table by the date. You can use CALCULATETABLE() function and add some conditions to get new tables.

    past =
    CALCULATETABLE ( 'raw number', 'raw number'[Date] < TODAY () )
    within 7 days =
    CALCULATETABLE (
        'raw number',
        'raw number'[Date] >= TODAY ()
            && 'raw number'[Date]
                <= ( TODAY () + 7 )
    )