I get every day multiple automatic emails. One has the subject 'Daily Report' and one has the subject 'Daily Report details'. This is the script I was using, but once the emails started coming without chronological order, I sometimes catch the wrong one.
var threads = GmailApp.search('Daily Report') //search gmail with the given query(partial name using * as a wildcard to find anything in the current subject name).
var msgs = GmailApp.getMessagesForThreads(threads);
Is there a way to tell the search that I want the mail with exact subject 'Daily Report' and not the one with 'Daily Report Details'?
Thanks