Solved

How do I select data up until the first space ?

Posted on 2009-05-20
1
510 Views
Last Modified: 2013-12-18
Hi,
My query is : select name from v$archived_log ;

X:\ORADATA\ARCHIVELOGS\1_7141_678967666.ARC
(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=tcp)(HOST=FTSDBGRD)(PORT=1521)))(CONNECT_DATA(SERVICE_NAME=guard_XPT.REGRESS.RDBMS.DEV.US.ORACLE.COM)(INSTANCE_NA
ME=facts)(SERVER=dedicated)))

I only want the log name X:\ORADATA\ARCHIVELOGS\1_7141_678967666.ARC  
not the tns connect string. Can I use substr and instr commands ? if so how ?
thanks.
0
Comment
Question by:partyon
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 11

Accepted Solution

by:
climbgunks earned 250 total points
ID: 24434210

SELECT SUBSTR(name, 1, INSTR(name, ' ')-1) FROM dual;

0

Featured Post

Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Let’s face it: one of the reasons your organization chose a SaaS solution (whether Microsoft Dynamics 365, Netsuite or SAP) is that it is subscription-based. The upkeep is done. Or so you think.
Lotus Notes has been used since a very long time as an e-mail client and is very popular because of it's unmatched security. In this article we are going to learn about  RRV Bucket corruption and understand various methods to Fix "RRV Bucket Corrupt…
This video explains at a high level with the mandatory Oracle Memory processes are as well as touching on some of the more common optional ones.
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…

622 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question