Returning cell value that contain specific text

Discuss the spreadsheet application
Post Reply
rosto
Posts: 6
Joined: Wed Dec 17, 2014 1:10 pm

Returning cell value that contain specific text

Post by rosto »

Hello,

I need a formula that returns the value of the cell, from range, that contains a specific text.
I attached a jpg to be more specific. Another formula gives me the result "2" and i need a formula to find in column A the cell that contains "2" and return the value of that cell. The result of the first formula is not possible to be found twice in column A.
Thanks.
Attachments
Clipboard01.jpg
OpenOffice 4.1.0 - Windows7 x64
Alex1
Volunteer
Posts: 852
Joined: Fri Feb 26, 2010 1:00 pm
Location: Netherlands, EU

Re: Returning cell value that contain specific text

Post by Alex1 »

Can you explain how you want the result displayed if more than one match is found?
In general a screenshot doesn't help much because we cannot see your formula and settings in use.
AOO 4.1.16 & LO 25.8.3 on Windows 10
rosto
Posts: 6
Joined: Wed Dec 17, 2014 1:10 pm

Re: Returning cell value that contain specific text

Post by rosto »

Sorry, perhaps I wasn't clear enough. If you read what i said in first post, you'll see that result of first formula can not be found twice (or more) in column A, so there can not be multiple results.
If you want, i attached now a simplified example.
Attachments
example.ods
(7.99 KiB) Downloaded 103 times
Last edited by rosto on Mon Aug 01, 2016 10:50 pm, edited 2 times in total.
OpenOffice 4.1.0 - Windows7 x64
User avatar
RoryOF
Moderator
Posts: 35203
Joined: Sat Jan 31, 2009 9:30 pm
Location: Ireland

Re: Returning cell value that contain specific text

Post by RoryOF »

Will the value to be found always be the last digit in the string to be searched? Will the strings cease at a9, or will they have vales such as a12or a22?
Apache OpenOffice 4.1.16 on Xubuntu 24.04.4 LTS
rosto
Posts: 6
Joined: Wed Dec 17, 2014 1:10 pm

Re: Returning cell value that contain specific text

Post by rosto »

In principle the first formula returns 3 letters text, so in column A can be 012, or 022, or fr2 but the first formula result will be in that form (012, 022, fr2).
Yes, the result of the first formula are the last 3 letters in column A list
OpenOffice 4.1.0 - Windows7 x64
Alex1
Volunteer
Posts: 852
Joined: Fri Feb 26, 2010 1:00 pm
Location: Netherlands, EU

Re: Returning cell value that contain specific text

Post by Alex1 »

If you isolate the numbers and copy them to a column inserted to the left of A, you can use the VLOOKUP function.
AOO 4.1.16 & LO 25.8.3 on Windows 10
User avatar
RusselB
Moderator
Posts: 6646
Joined: Fri Jan 03, 2014 7:31 am
Location: Sarnia, ON

Re: Returning cell value that contain specific text

Post by RusselB »

If I understand correctly, you want to search through column A for a partial match where the matching portion is in Sheet1.A1
Check sheet3 of this attachment
Attachments
example.ods
(9.88 KiB) Downloaded 101 times
OpenOffice 4.1.7, LibreOffice 7.0.1.2 on Windows 7 Pro, Ultimate & Windows 10 Home (2004)
If you believe your problem has been resolved, please go to your first post in this topic, click the Edit button and add [Solved] to the beginning of the Subject line.
rosto
Posts: 6
Joined: Wed Dec 17, 2014 1:10 pm

Re: Returning cell value that contain specific text

Post by rosto »

It's ok and correct.
If i have the second column, I know how to solve the problem, but I receive the column A from accounting department, from other application and it have hundreds of rows, so i hoped that is not necessary to lick every cell to create a second column.
OpenOffice 4.1.0 - Windows7 x64
Post Reply