Home » SQL & PL/SQL » SQL & PL/SQL » output lines for a select query (oracle10g, 10g, aix5.2)
output lines for a select query [message #422949] Mon, 21 September 2009 07:05 Go to next message
chandu_imax
Messages: 46
Registered: May 2008
Location: Hyderabad
Member
Hi All

When we run any of the sql query, It will display 8 lines, after that it will display another 8 lines and so on...

But i want that the query should give the output continuously. We can get it if we set heading off.

Apart from that is there any other way to get 100 lines per heading like that ?


Please suggest me. Suppose we will take an example:

SQL> select * from XYZ;

BANK
--------
SCB
HSBC
TAIB
BBB0
OTH
BILL
BIBD
12457
a
a

BANK
--------
hi

j
a
1
1
2
qaqa
as
1
BANK
--------
hai
sadf
a
sad
HI
hd
as
BANK
-------
i
p
zaq
c
h
a
n
q
a
x

43 rows selected.

Above will be the output. But i require like below.

BANK
--------
SCB
HSBC
TAIB
BBB0
OTH
BILL
BIBD
12457
a
a

hi

j
a
1
1
2
qaqa
as
1
hai
sadf
a
sad
HI
hd
as
i
p
zaq
c
h
a
n
q
a
x

43 rows selected.
Thanks in advance....

Re: output lines for a select query [message #422950 is a reply to message #422949] Mon, 21 September 2009 07:10 Go to previous messageGo to next message
Mahesh Rajendran
Messages: 10671
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
Fix your pagesize.
http://www.orafaq.com/wiki/SQL*Plus_FAQ#What_commands_can_be_executed_from_SQL.2APlus.3F
Re: output lines for a select query [message #422951 is a reply to message #422950] Mon, 21 September 2009 07:13 Go to previous messageGo to next message
chandu_imax
Messages: 46
Registered: May 2008
Location: Hyderabad
Member
Hi,

Very Smart answer... Smile Thanks a lot again.

Re: output lines for a select query [message #422952 is a reply to message #422949] Mon, 21 September 2009 07:15 Go to previous messageGo to next message
Michel Cadot
Messages: 63818
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
SQL*PlusĀ® User's Guide and Reference
Chapter 12 SQL*Plus Command Reference
Section SET System Variable

Please read OraFAQ Forum Guide, especially "How to format your post?" section.
Make sure that lines of code do not exceed 80 characters when you format.
Indent the code (See SQL Formatter), use code tags and align the columns in result.
Use the "Preview Message" button to verify.
Also always post your Oracle version with 4 decimals.

Regards
Michel
Re: output lines for a select query [message #423072 is a reply to message #422949] Tue, 22 September 2009 00:53 Go to previous messageGo to next message
nirmalorafaq
Messages: 2
Registered: September 2009
Location: Bangalore
Junior Member
in sql*plus type environment pagesize 10000

sql> set pagesize 10000
Re: output lines for a select query [message #423083 is a reply to message #422949] Tue, 22 September 2009 01:14 Go to previous message
chandu_imax
Messages: 46
Registered: May 2008
Location: Hyderabad
Member
Hi All,

Thanks to every one. Got the solution for it.

Thank you Michel. I will follow the instructions from now onwards.


Regards,
Chandu.
Previous Topic: NUMBER(1) or CHAR(1) for flag?
Next Topic: pad number when no decimals
Goto Forum:
  


Current Time: Sat Oct 01 05:57:03 CDT 2016

Total time taken to generate the page: 0.13402 seconds