1
votes

I have this data in Google Sheets cells:

Dom\SKUto\ctures\VN_0001.png
Dom\SKUto\ctures\sinom\VN_0002.JPG
Dom\SKUto\ctures\folder\VN_0003.jpg
pictures\folder\VN_0004.jpg

I want to return in another cell only the last part of it (the picture name and extension)

VN_0001.png
VN_0002.JPG
VN_0003.jpg
VN_0004.jpg

How do I do that in Google Sheets?

1
Does this help =TRIM(RIGHT(SUBSTITUTE(A1,"/",REPT(" ",100)),99))? You haven't mentioned which tool to use. - Serge de Gosson de Varennes
Hi Serge, no it doesn't work. I use google sheets - Simon GIS

1 Answers

2
votes

Please try the following formula

=ArrayFormula(REGEXREPLACE(Q2:Q,"(.*\\)(.*)$","$2"))

OR

=ArrayFormula(IF(Q2:Q="",,(REGEXEXTRACT(Q2:Q,".*\\(.*)$"))))

(adjust ranges to your needs)

enter image description here