Flow designer look up action based on date does not return the expected result
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-11-2025 09:06 AM - edited 03-11-2025 09:12 AM
Hey all,
I need to look up on hardware assets records where
- Asset function == primary
- Warranty Expiration == today + 2 months (this is a custom field of Date type).
I set up the flow on Flow Designer:
1. Set the flow variable to 2 months from now:
2. Look up records:
All looks fine.
I have a record that meets the conditions:
I run a test. The variable is set correctly:
The lookup is run okay:
However, as you can see, the record is not returned.
When I set the filter before or after, it does not work either.
Any one has any idea why?
I tried to write a script to see what happens.
This script returns all records.
So, something seems to be wrong but I don't know why.
Any ideas?
Thanks.
Best,
Firat
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-11-2025 09:11 AM
I'm not an expert, but based on what I've learned, let's try to break this condition into two parts. First, try to get Asset function == primary and check if the records are coming or not. If yes, then add another condition. This will help us determine whether the issue is with the condition itself or something else.
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.
Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/atul_grover_lng [ Connect for 1-1 Session]
****************************************************************************************************************
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-11-2025 09:20 AM
Hi, thanks!
Asset function works, it is the date that does not work.
It seems that adding a custom flow variable as a condition to compare does not work in any case (I tried before after as well). Weird.
Best,
Firat
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-11-2025 09:27 AM
Might be helpful
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.
Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/atul_grover_lng [ Connect for 1-1 Session]
****************************************************************************************************************
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-11-2025 09:53 AM
try to give the filter as this
Warranty Expitation = Flow Variable
If my response helped please mark it correct and close the thread so that it benefits future readers.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader