This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. We're covering it all. You won't want to miss it.
Learn moreGet Fabric Certified for FREE during AI Skills Fest. This week only. Secure your voucher now.
Hello. I need a line of M Code that will NOT filter the following [VOIDSTTS] of 0; [VOIDSTTS] of 1 where [VOIDDATE] > AsOfDate.
Right now, the AsOfDate is 9/6/2025. Here are what the two columns look like and the third column is what result I am after:
| [VOIDSTTS] | [VOIDDATE] | KEEP OR FILTER OUT? |
| 0 | 1/1/1900 | KEEP |
| 0 | 1/1/1900 | KEEP |
| 1 | 7/7/2025 | FILTER OUT |
| 1 | 10/1/2025 | KEEP |
| 0 | 1/1/1900 | KEEP |
| 1 | 8/4/2024 | FILTER OUT |
| 0 | 1/1/1900 | KEEP |
| 0 | 1/1/1900 | KEEP |
| 1 | 9/7/2025 | KEEP |
Solved! Go to Solution.
If [VOIDSTTS] are of Text data type, and [VOIDDATE] are Date, you can do this by adding a step in M,
Table.SelectRows(#"laststep",
each
[VOIDSTTS] = "0" or ([VOIDSTTS] = "1" and [VOIDDATE] > #date(2025, 9, 6))
)
@rmcgrath Try the following:
Table.SelectRows(#"Changed Type", each ([#"[VOIDSTTS]"] = 0 or [#"[VOIDDATE]"] > #date(2025, 9, 6) ))
If [VOIDSTTS] are of Text data type, and [VOIDDATE] are Date, you can do this by adding a step in M,
Table.SelectRows(#"laststep",
each
[VOIDSTTS] = "0" or ([VOIDSTTS] = "1" and [VOIDDATE] > #date(2025, 9, 6))
)
Check out the May 2026 Power BI update to learn about new features.
Sign up to receive a private message when registration opens and key events begin.
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
| User | Count |
|---|---|
| 4 | |
| 3 | |
| 3 | |
| 1 | |
| 1 |