Forum Discussion

jmi1071's avatar
jmi1071
Copper Contributor
Jul 03, 2024

Formula to Match Text in range and return text from another range

I have text in two columns on sheet 1

I am imputing text from column B of sheet 1 into column F of sheet 2.  

Need a formula that will match text and return text to G2 from same row of sheet1 but from column A

In this example G2 should return "__import__.product_031"

 

Thank you in advance for the help.

 

 

2 Replies

  • jmi1071 

    In G2:

    =XLOOKUP(F2, 'Sheet 1'!$B$2:$B$1000, 'Sheet 1'!$A$2:$A$1000, "")

     

    where Sheet 1 is the name of the first sheet. Adjust the ranges if you have more than 1000 products on that sheet.

    Then fill down.

    If you have an older version of Excel that does not have XLOOKUP:

     

    =IFERROR(INDEX('Sheet 1'!$A$2:$A$1000, MATCH(F2, 'Sheet 1'!$B$2:$B$1000, 0)), "")

Resources