Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Pages - Design & Build
Suggested answer

User Local Date & Time In FetchXml

(0) ShareShare
ReportReport
Posted on by 20

Hi, I’m working with FetchXML and using a condition to filter records based on the modifiedon date using the "on or before" operator. The issue is that the date value is in UTC format, which is 5 hours behind my local timezone (Pakistan Standard Time). I need a way to filter the records using the user’s local date and time, regardless of their region, so that the query results reflect real-time data accurately.

Is there a syntax or best practice to achieve this in FetchXML?

 
<condition attribute="modifiedon" operator="le" value="{{ now | date: 'yyyy-MM-dd HH:MM' }}" />
Categories:
  • Suggested answer
    stampcoin Profile Picture
    2,133 on at

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Michael Gernaey – Community Spotlight

We are honored to recognize Michael Gernaey as our June 2025 Community…

Congratulations to the May Top 10 Community Leaders!

These are the community rock stars!

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

Leaderboard >

Featured topics