Date: Tue, 6 Oct 2009 12:49:55 -0500
Wait, wait, wait. Careful there with colsep. Setting that to "" will remove the space between columns in a report. So,
Set colsep ""
Select city,state from tab;
SAN FRANCISCOCA There are an awful lot of set commands. The two you want are SQLPROMPT which will get rid of the SQL> SQL> SQL> and SQLNUMBER which will get rid of the 2 3 4...13.
I happen to be fond of others. I like set pages 0. I like set ver off. I like managing my feedback. But what you are asking for are SQLPROMPT and SQLNUMBER.
If you are interested in learning more, check out any of the myriad of sites which discuss the SET command.
[mailto:oracle-l-bounce_at_freelists.org] On Behalf Of Rich Jesse Sent: Tuesday, October 06, 2009 11:37 AM To: oracle_l
Subject: Re: sqlplus
> I have a shell script report the following output for my daily check
> routine. I found the SQL> SQL> SQL> is very annoying, is it possible
> get rid off the "lines from coonected to:" to 2 3 4...13" ?
I've needed to include these settings in the shell I'm working on in
to make sure that the login.sql/glogin.sql settings do not interfere with
the output format (10.1 on AIX):
set heading off trimout on tab off echo off termout on colsep "" verify
feedback off newpage 0 linesize 80 pagesize 100 showmode off
There may be more! These are only the ones that affected my output. I
needed to use "cut" to trim the output, like this:
my_status=`sqlplus -s / _at_$ADMIN/my.sql|cut -f 10 -d " "`
And, as others have mentioned, use "-s" with "sqlplus" to silence the
It seems like all of this is more excessive than I've used in the past,
it works consistently for me.