-
Suggestion
-
Resolution: Unresolved
-
None
-
2
-
Problem Definition
Sometimes, comparing against a dynamic value is needed.
As an example, if I would like to return all Assets Objects where an Attribute on the Object matches an Attribute on a referenced Object, I can't do that.
Such as with these Object Types:
- Laptops
- Warranties
Where Laptops has a Retire Date Attribute.
And it has a Warranty Attribute pointing to a warranty in Warranties that has a Expire Date Attribute.
And I would like to return all Objects in Laptops who's Warranties end before their Retire Date.
Currently, that's not possible since the right side of the comparison in AQL Queries is static.
Suggested Solution
Allow for this AQL to be used:
"Retire Date" < ["Warranty"."Expire Date"]
Where the [] are just a way to tell Assets to interpret the string as a dynamic reference.
Something else could be used, but that's the idea.
If this could be done on a single Object, that would be helpful too.
Such as if I wanted to check if a Laptop's Assigned Date was before it's Last Maintenance Date:
"Assigned Date" < ["Last Maintenance Date"]
Workaround
Currently, there is no known workaround for this, except to programmatically check each Object individually, such as with Automation & Branching, or via a software script that interacts with the Assets AQL REST API, which means many requests, usually.