Solved

display

Posted on 2014-02-26
4
132 Views
Last Modified: 2014-10-15
SYS@sprefuat1> select * from dba_directories;

OWNER                          DIRECTORY_NAME
------------------------------ ------------------------------
DIRECTORY_PATH
--------------------------------------------------------------------------------
SYS                            DUMP_FILES2
/backup/ora_export

SYS                            DATA_PUMP_DIR
/ora102_home/app/oracle/product/10.2.0/rdbms/log/

SYS                            DUMP_FILES
/ora_export


OWNER                          DIRECTORY_NAME
------------------------------ ------------------------------
DIRECTORY_PATH
--------------------------------------------------------------------------------
SYS                            WORK_DIR
/ora102_home/app/oracle/product/10.2.0/work

SYS                            ARROWGB
/local/apps/cmp01/ext_link

SYS                            FDE_DS
/glpfeeds/input


OWNER                          DIRECTORY_NAME
------------------------------ ------------------------------
DIRECTORY_PATH
--------------------------------------------------------------------------------
SYS                            SNP_MANUFACTURE
/glpfeeds/output

SYS                            GLP_MANUFACTURE
/glpfeeds/output

SYS                            GLP_DATA_LOAD
/glpfeeds/input


OWNER                          DIRECTORY_NAME
------------------------------ ------------------------------
DIRECTORY_PATH
--------------------------------------------------------------------------------
SYS                            DUMP_EXADATA
/backup6

SYS                            ORACLE_OCM_CONFIG_DIR
/ora_home/app/oracle/product/10.2.0/ccr/state

SYS                            TMP
/tmp


12 rows selected.

SYS@sprefuat1>




How will I format this display..

In a viewable format..
0
Comment
Question by:thomasliju
4 Comments
 
LVL 29

Accepted Solution

by:
MikeOM_DBA earned 500 total points
ID: 39889486
Try:
SET LIN 120 PAGES 49999
COL OWNER FOR a20
COL DIRECTORY_NAME FOR a32
COL DIRECTORY_PATH FOR a58 WRA
SELECT * FROM Dba_Directories;

Open in new window

0
 
LVL 73

Expert Comment

by:sdstuber
ID: 39889490
set linesize 1000
column directory_path format a50

then run your query
0
 
LVL 22

Expert Comment

by:Steve Wales
ID: 39889651
The above advice works fine for this specific query (where the output isn't really that wide).

Sometimes you'll query views or tables with lots of columns that you just can't get to display  "neatly" on a screen.

If you want to get information out in a more legible format, you would need to use a third party tool.

You can use MS Excel to query a database and return the rows into the spreadsheet.
You could use SQL Developer (free, from Oracle Corp)
You could use PL/SQL Developer (paid, form Allround Automations)
WinSQL is also an option (I believe there is a free Lite version, or there used to be at least - but it's mainly a paid product).

Depending upon your needs, one of these options might work (although each requires some level of configuration on your client platform in order to make the connection to the database).
0
 

Author Closing Comment

by:thomasliju
ID: 40383669
yes this really helped.


Thank you
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Join & Write a Comment

Subquery in Oracle: Sub queries are one of advance queries in oracle. Types of advance queries: •      Sub Queries •      Hierarchical Queries •      Set Operators Sub queries are know as the query called from another query or another subquery. It can …
How to Unravel a Tricky Query Introduction If you browse through the Oracle zones or any of the other database-related zones you'll come across some complicated solutions and sometimes you'll just have to wonder how anyone came up with them.  …
This video explains at a high level about the four available data types in Oracle and how dates can be manipulated by the user to get data into and out of the database.
This videos aims to give the viewer a basic demonstration of how a user can query current session information by using the SYS_CONTEXT function

708 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

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now