Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Microsoft is giving away 50,000 FREE Microsoft Certification exam vouchers. Get Fabric certified for FREE! Learn more

Reply
EaglesTony
Post Prodigy
Post Prodigy

Error filtering my records in PowerQuery to only select those records with due date <= todays date

I am trying to filter my records to only select those records where the due date <= todays date.

 

I have the following:

= Table.SelectRows(#"Renamed Columns", each [DUE_DATE] <= DateTime.Date(DateTime.LocalNow))

 

However I am getting "Expression.Error: The DateTime.Date function expects and input of type DateTime or DateTimeZone"

 

My DUE_DATE field I change to type date.

1 ACCEPTED SOLUTION
HotChilli
Super User
Super User

DateTime.LocalNow is a function so you need to call it with brackets, DateTime.LocalNow()

View solution in original post

1 REPLY 1
HotChilli
Super User
Super User

DateTime.LocalNow is a function so you need to call it with brackets, DateTime.LocalNow()

Helpful resources

Announcements
PBIApril_Carousel

Power BI Monthly Update - April 2025

Check out the April 2025 Power BI update to learn about new features.

Notebook Gallery Carousel1

NEW! Community Notebooks Gallery

Explore and share Fabric Notebooks to boost Power BI insights in the new community notebooks gallery.

April2025 Carousel

Fabric Community Update - April 2025

Find out what's new and trending in the Fabric community.

Top Solution Authors