Link to home
Start Free TrialLog in
Avatar of tech-sys
tech-sys

asked on

How to restrict SQLPlus output screen...?

How to restrict select statement output in SQL Plus so that It will wait for user to wait till user hits enter or space to see next page of results / rows... Instead of displaying all in a one shot?

I know about set linesize X but that will split the output after X number of lines but it will display all 100 or 1000 rows in one shot... I need to see or hold first 100 results and then I want to hit enter or space to see next 100 results...
Avatar of Aaron Shilo
Aaron Shilo
Flag of Israel image

set pause on
Avatar of Sean Stuber
Sean Stuber

pipe the output through "more" or a similar utility
ASKER CERTIFIED SOLUTION
Avatar of Darius Ghassem
Darius Ghassem
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
I would go with pause but add one more command after the set pause on

set pause 'hit enter to continue...'

otherwise you'll have a blank line
Avatar of tech-sys

ASKER

Perfect I followed following steps..... and its working...

Set pause on
Set pagesize 75
Excellent help... Thanks A Lot...
i think this isent fair since i gave the same answer first :-(
>>Perfect I followed following steps..... and its working...

Bet you money that someday soon, you'll run a query that should take seconds and will wonder why it isn't returning...

It's because pause in 'on' has no prompt.
>>i think this isent fair since i gave the same answer first

Not the same.  You didn't post pagesize.