Posts

Showing posts from October, 2022

Google Sheet - Query Function

 Google Sheet - Query Function = QUERY ( 'Rent Payment Summary'!I1:M4 , "Select DateDiff(M,L)/365 label DateDiff(M,L)/365 'Age' format DateDiff(M,L)/365 '#,##0'" , 1 ) = QUERY ( { ARRAYFORMULA ( LEFT ( I:I , 3 ) ) } , "Select * label Col1 'Code'" , 1 ) https://developers.google.com/chart/interactive/docs/querylanguage#Options = QUERY ( 'Form Responses 1'!A:E , "Select * where A is not Null" , 1 ) //Here A is column Name. Query(data, query statement, headers) = QUERY ( 'Rent Payment Summary'!I:L , "Select *" , 1 )

How to Filter Emails in GMail and Read Email Body Using GAS?

 How to Filter Emails in GMail and Read Email Body Using GAS? function   getThreadSummariesV3 (){    const   threads = GmailApp . getInboxThreads (); //Reads first 500 emails only.    //Logger.log(threads.length)    let   pValue = 0 ;    let   myBody = '' ;    let   mySubject = '' ;    let   booSub = '' ;    //let recCount=0;    const   sh = SpreadsheetApp . getActiveSpreadsheet (). getSheetByName ( 'Sheet3' )    threads . forEach ( function ( thread ){      //recCount+=1;      const   lRow = sh . getLastRow ()+ 1 ;      //if (recCount<100){        const   threadId = GmailApp . getThreadById ( thread . getId ());        const   threadMsgs = threadId . getMessages ();     ...