Hi @lpruit2 ,
 
I tried below script in the flow but it is fetching all records and not just the records which are created 15 days ago.
 
 
// Create GlideDateTime objects for 15 and 22 days ago
var today = new GlideDateTime();
var fifteenDaysAgo = new GlideDateTime();

// Subtract 15 and 22 days from today
fifteenDaysAgo.addDays(-15); // 15 days ago
 
// Define the conditions for the lookup (RITM table)
var gr = new GlideRecord('sc_req_item'); // RITM table (Request Item)
gr.addEncodedQuery(
  'stage=waiting_for_approval^stateIN-5,1^approvalNOT INapproved,rejected' +
  'sys_created_on' + fifteenDaysAgo.getValue()
);

// Execute the lookup and check if there are any matching records
gr.query();