# Match Data from Spreadsheet to Search Results in Table, Click Correct one

**URL:** <https://forum.katalon.com/t/match-data-from-spreadsheet-to-search-results-in-table-click-correct-one/22455>\
**Category:** Web Testing\
**Tags:** katalon-studio\
**Created:** [April 3, 2019, 8:49pm UTC](https://forum.katalon.com/t/match-data-from-spreadsheet-to-search-results-in-table-click-correct-one/22455 "2019-04-03T20:49:43Z")\
**Posts on this page:** 1\
**Showing post:** 7

<div class="post-metadata">

**Author:** ![B\_L](https://dub1.discourse-cdn.com/katalon/user_avatar/forum.katalon.com/b_l/32/976_2.png) [@B\_L](https://forum.katalon.com/u/B_L)\
**Post date:** [April 9, 2019, 1:03pm UTC](https://forum.katalon.com/t/match-data-from-spreadsheet-to-search-results-in-table-click-correct-one/22455/7 "2019-04-09T13:03:36Z")

</div>

Sorry for the delayed response, been busy 🙂

This helps:

```auto
//*[@id=“search_results_container”]/div/div/div/div[2]/a[1]/h4/text()

```

With this a few things. First if you go with text for some reason Katalon seems to not like that. Also you will notice the “a” it has “a[1]” meaning the first a. so we remove the 1 and it will look for any a

```auto
//*[@id=“search_results_container”]/div/div/div/div[2]/a/h4/text()

```

We can then apply the contains like this

```auto
//*[@id=“search_results_container”]/div/div/div/div[2]/a/h4/text()[contains(.,"Princess Belle")

```

Note I have “.” because we already call out we are looking for the text. please try this xpath. this SHOULD allow you to highlight the text. However this will still not be enough to identify the object so I would also add in parent. like this:

```auto
//*[@id=“search_results_container”]/div/div/div/div[2]/a/h4/text()[contains(.,"Princess Belle")/parent::a

```

This SHOULD highlight the a for you. it will be a very small highlight but should work for your purposes. Let me know. Ideally if this works you should then be able to change it to your variable and use it.

```auto
//*[@id=“search_results_container”]/div/div/div/div[2]/a/h4/text()[contains(.,searchResults)

```

---

_[View the full topic](https://forum.katalon.com/t/match-data-from-spreadsheet-to-search-results-in-table-click-correct-one/22455)._
