Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Pull name of pdf from column

Status
Not open for further replies.

jasonhuibers

Programmer
Sep 12, 2005
290
CA
Table = Employees
Column1 =
Using a SELECT statement I want to return the name of the pdf file from Column1 (ie: EmployeeName.pdf)

How can I do this using a SELECT statement
 
Jason -
Can you tell us what you've tried so far?
If you use INSTR to find the position of the last "/", you can then use SUBSTR to get everything after that position.
 
Building upon Carp's excellent suggestion:

Code:
select * from jason;

COLUMN1
-------------------------------------
[URL unfurl="true"]https://ebay.com/sec/EmployeeName.pdf[/URL]

1 row selected.

select substr(column1,instr(column1,'/',-1)+1) results from jason;

RESULTS
----------------
EmployeeName.pdf

1 row selected.

Let us know if you have additional questions.

[santa]Mufasa
(aka Dave of Sandy, Utah, USA)
“People may forget what you say, but they will never forget how you made them feel.
 
I used this: it worked for me...
SELECT SUBSTR(it.comments , INSTR(it.comments,'/', -1, 1)+1)
FROM Feedback it;
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top