ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Search function. (https://www.excelbanter.com/excel-worksheet-functions/102908-search-function.html)

the_intern

Search function.
 
Hello everybody,
does anyone know what funtion to use when searching for a value in a
given excel file using the values in TWO COLUMNS together as a one
unique search "key"?

If we think SQL it might have been something like this

SELECT excelcell
WHERE thisexcelsheet.A1 = thatexcelsheet.columnA1
AND thisexcelsheet.columnB1 = thatexcelsheet.columnB1

I know that was badly explained but if anyone understood what I´m
after, feel free to help me out ;)
Thanks!
Havard


Pete_UK

Search function.
 
You could join the two columns together in a helper column and use that
as the search column.

Hope this helps.

Pete

the_intern wrote:
Hello everybody,
does anyone know what funtion to use when searching for a value in a
given excel file using the values in TWO COLUMNS together as a one
unique search "key"?

If we think SQL it might have been something like this

SELECT excelcell
WHERE thisexcelsheet.A1 = thatexcelsheet.columnA1
AND thisexcelsheet.columnB1 = thatexcelsheet.columnB1

I know that was badly explained but if anyone understood what I´m
after, feel free to help me out ;)
Thanks!
Havard



the_intern

Search function.
 
Hi there Pete,
I was thinking about that as well, but the downside is that it would
make my excel sheets even more filled with repeating data... and they
are really messy enough as it is ;)

Besides, these excel sheets are shared with a lot of people using them
for different purposes, so a change in the set-up of the spreadsheets
would mean that a lot of people might have to be informed and do a lot
of minor changes to their spreadsheets.

So, what I´m looking for is a way to do this that doesnt imply having
to change the spreadsheet that I´m reading from.

I´m sure there´s a clever function to do this, but my excel skills
are quite limited.
Thanks for the reply, though!


Pete_UK ha escrito:

You could join the two columns together in a helper column and use that
as the search column.

Hope this helps.

Pete

the_intern wrote:
Hello everybody,
does anyone know what funtion to use when searching for a value in a
given excel file using the values in TWO COLUMNS together as a one
unique search "key"?

If we think SQL it might have been something like this

SELECT excelcell
WHERE thisexcelsheet.A1 = thatexcelsheet.columnA1
AND thisexcelsheet.columnB1 = thatexcelsheet.columnB1

I know that was badly explained but if anyone understood what I´m
after, feel free to help me out ;)
Thanks!
Havard




All times are GMT +1. The time now is 06:36 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com