web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Supply chain | Supply Chain Management, Commerce
Suggested Answer

Advance filter on dates - (LessThanUtcNow()) but not blank

(7) ShareShare
ReportReport
Posted on by 93
Hello,
 
I am trying to apply an advance filter on confirmed receipt date for open purchase orders.
 
I want to apply both (LessThanUtcNow()) and is not blank. Otherwise, the (LessThanUtcNow()) filter alone will display blank values, which I do not want.
 
I have tried a few without success:
  • >01011900
  • !""
 
 
Any ideas?
 
Thank you in advance!
I have the same question (0)
  • Adis Profile Picture
    6,686 Super User 2026 Season 1 on at
    Hi,
     
    Right from the gut I would try to apply the BETWEEN syntax => 01.01.1900..(LessThanUtcNow())
     
    I would also check:
    -if the two values work separately, ie. filter by no blanks OR (LessThanUtcNow()). Instead of using !"" or >01011900, try using a date before the first purchase order ever created in the system.
    -Instead of (LessThanUtcNow()), try using a date. Maybe the function works as a stand alone function but not in combination.
     
    Kind regards, Adis
     

    If this helped, please mark it as "Verified" for others facing the same issue

  • Laurens vd Tang Profile Picture
    4,758 Super User 2026 Season 1 on at
    Good day,
     
    Could you try it with (LessThanUtcNow()) , !"" 
     
    Best regards,
    Laurens van der Tang
  • Suggested answer
    Mohamed Amine Mahmoudi Profile Picture
    26,803 Super User 2026 Season 1 on at
     
    You need to use >T instead of (LessThanUtcNow()) because it also contains null values 
     
    Best regards,
    Mohamed Amine MAHMOUDI
  • Waed Ayyad Profile Picture
    9,135 Super User 2026 Season 1 on at
    Hi,
     
    Can you tell me what is the data that you want to filter? for example, do you want to return records that have confirm receipt date > 1/1/1900? 
     
     
    Thanks,
    Waed Ayyad
     
  • jwell22 Profile Picture
    93 on at
    Thanks all for your responses so far, but unfortunately none of the suggestions work.
     
    I'm still getting blank values come through.
     
    The data I'm trying to filter is on lines where the confirmed receipt date is:
    • A date in the past (not including today)
    • Not blank
  • Waed Ayyad Profile Picture
    9,135 Super User 2026 Season 1 on at
    Hi,
     
    To be clear do you want to get all records < today () and not blank?
     
     
    Thanks,
    Waed Ayyad
     
     
  • jwell22 Profile Picture
    93 on at
    That's right. So I want to see POs which are late.
  • Martin Dráb Profile Picture
    239,451 Most Valuable Professional on at
    The problem with yours, lvdtang's and Mohamed's approaches is that they're combining the ranges with OR operator, not AND.
     
    A good approach may be creating a custom query range util method, similar to lessThanUtcNow(), but excluding empty values.
  • Suggested answer
    Mohamed Amine Mahmoudi Profile Picture
    26,803 Super User 2026 Season 1 on at
     
    the first solution works very well for me.

    if not, I suggest this solution: put 1901 instead of 1900.
     
     
    Best regards,
    Mohamed Amine MAHMOUDI
  • jwell22 Profile Picture
    93 on at
    This one is almost perfect, except I don't want to filter on today's date (T), instead I want yesterday.
    • The idea being that I capture POs that are "late"
    I have tried (Day(-1)) but this does not work either.
     

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Meet the Microsoft Dynamics 365 Contact Center Champions

We are thrilled to have these Champions in our Community!

Congratulations to the April Top 10 Community Leaders

These are the community rock stars!

Leaderboard > Supply chain | Supply Chain Management, Commerce

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 155 Super User 2026 Season 1

#2
Laurens vd Tang Profile Picture

Laurens vd Tang 101 Super User 2026 Season 1

#3
Zain Mehmood Profile Picture

Zain Mehmood 89 Most Valuable Professional

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans