Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How to configure SQL*Plus to display all columns on one row?

765854Apr 12 2010 — edited Apr 12 2010
When I select from a table that contains large columns with a datatype like varchar(100) it displays that column on its own row. I guess it's doing this because it's allocating space for every character in that column even though that space may be unused.

For example if we have a table users:


Name Null? Type
----------------------------------------- ---------------- -------------
ID NOT NULL NUMBER(10)
FNAME NOT NULL VARCHAR2(50)
LNAME NOT NULL VARCHAR2(50)

the following select statement, select * from users, will display the following:

ID FNAME
---------- ------------------------------------------------
LNAME
--------------------------------------------------
1 John
Smith

2 Roger
Stevens

3 Ginger
Adams

Obviously there is more than enough space for LNAME. Is it possible to make all columns to appear on the same row in this case?
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on May 10 2010
Added on Apr 12 2010
2 comments
2,338 views