GlideRecord addQuery comparing a field value to a field value from another table stored in variable
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-02-2024 12:44 AM - edited 04-02-2024 12:47 AM
I want to do something simple like this:
var task = new GlideRecord('pm_project_task')
task.addQuery('top_task',project.number)
where project.number is a field from another table. I have queried the entire pm_project_task table and checked manually for a match between top_task and project.number and that works.
Just trying to figure out how to check a field against a variable in addQuery. If this can be solved differently, great.
for context the project.number is generated dynamically so I cant do: table > filter the record as needed > right click on the query end >do a copy query> use it in encoded query
thanks in advance.