regexgoogle-sheetsgoogle-sheets-formulaarray-formulasutm-tracking

Extract UTM parameters in Google Sheets


I need to extract UTM parameters in Google Sheets and I have, I believe, a simple question.

I would like to extract the value associated to the utm_campaign in column A to column B:

Example

If possible, I would like to keep the opportunity to do an Arrayformula for all the lines in column A and avoid using a script to do so.


Solution

  • try:

    =ARRAYFORMULA(IFNA(REGEXEXTRACT(A2:A, "utm_campaign"":""(\d+)")))
    

    0