Forum Discussion
Apply Filter from specific date
Hi All,
I have last 30 days data with columns Region, etc. Requirement is to apply filter like Region does not contain USA and Mexico from specific date like 20/04/20203. How to achive this. Please suggest
Regards,
Suren
see my videohttps://1drv.ms/v/s!AiUZ0Ws7G26Rh3ErTgr710-MAzvV?e=L50uvi
Sample PBIX file attached
https://1drv.ms/u/s!AiUZ0Ws7G26Rh3CTPlsBn409Ozfo?e=pKtsW4= Table.SelectRows( from, (x)=> not List.ContainsAny( Record.FieldValues(x),{"USA","Mexico"},Comparer.OrdinalIgnoreCase) and x[Date] = #date(2023, 5, 2))
7 Replies
- AhmedxSuper User
pls try this
Measure = CALCULATE( CALCULATE(SUM('Table'[Value]), KEEPFILTERS( NOT'Table'[Region] in {"USA","Mexico"}), KEEPFILTERS( 'Table'[Business Days]= DATEVALUE("5/2/2023") ) ))- AnonymousNot applicable
Thank you so much for your time.
Due to other limitations, we want to achive same in query editor. Please let me know how to achive
- AhmedxSuper User
see my videohttps://1drv.ms/v/s!AiUZ0Ws7G26Rh3ErTgr710-MAzvV?e=L50uvi
Sample PBIX file attached
https://1drv.ms/u/s!AiUZ0Ws7G26Rh3CTPlsBn409Ozfo?e=pKtsW4= Table.SelectRows( from, (x)=> not List.ContainsAny( Record.FieldValues(x),{"USA","Mexico"},Comparer.OrdinalIgnoreCase) and x[Date] = #date(2023, 5, 2))
- AhmedxSuper User
or
- AnonymousNot applicable
Thank you so much for your time. Please let me know how to achive same in query editor
- AhmedxSuper User
or
= Table.SelectRows( from, (x)=> not List.ContainsAny( {x[Region]},{"USA","Mexico"},Comparer.OrdinalIgnoreCase) and x[Date] = #date(2023, 5, 2))