sqlplus: could it be dirrected do not printout anything, beside results?
I try to prepare a sufficient function to execute a sql-statement, getting back ONLY retrieved results!
What I can't figured out how to make the sqlplus not printing the 'Connected to ...', 'Disconnected from...' and the executed statements after 'SQL> '.
I am under impression that having the sqlplus suppress that information by itself, than filtering it outside of the sqlplus by 'grep' or 'sed', will be quicker
I have tried the
'sqlplus $cred @sql_script' and
'sqlplus $cred <<EofSQL'
Last one works better, but I am spooling and filtering the '^SQL> ' lines.
I would like to do not involve the 'sed ' and spool file.
Would be the best to make sqlplus avoid printing beginning and end information and accept SQL-statements silently!
Does anyone know how and if it possible at all to do?
That what I have by now (just for reference)
Appreciate replay, vbe, but doesn't work. (Actualy, I have tried that already. Maybe there is something that prevent that sets to work?)
I need just like this:
Is there any way to make those sets to work, or any other way to eliminate those stuff??
Yes, durden_tyler, that '-s' is what I was looking for! Appreciate it!!
One difference from your example is that for me the 'connect ..' command always shows '>connected' output (but I did not redirect to file; I use std-output; but, it shouldn't be a matter, right)
It is not a problem, just surprising. I have changed '/NOLOG' to the connection string (in my exml it is $AIM_PSWD) and 'connected ' disapeared.
Hi everybody!
need some awk-support. i want a line-selective printout of a file.
wat i normally will do with ...
awk ' FNR==8' sample.txt
But now i need the data from line 8, 10 and the following data from line13 to 250 wich is not end of the file. I tried allready to combine it but without... (2 Replies)
i am using bash shell
Whenever i declare an array, and then using sqlplus, i am getting sqlplus error and return code 127.
IFS=","
declare -a Arr=($Variable1);
SQLPLUS=sqlplus -s "${DBUSER}"/"${DBPASS}"@"${DBASE}
echo "set head off ; " > ${SQLCMD}
echo "set PAGESIZE 0 ;" >> ${SQLCMD}... (6 Replies)
trying to find online or a book.
the words to use to find 'a' or
'the ways and means' to format left margin, right margin etc from man pages to Hardware Printer.
while looking to print man pages with a Hardware Printer.
I have found lp.
and did a
man sudoers | lp -p2
to test.
The... (1 Reply)
Hello ,
When using vim, can ctag and cscope support recording search results and displaying the history results ? Once I jump to one tag, I can use :tnext to jump to next tag, but how can I display the preview search result? (0 Replies)
hi all,
i am writing a ksh script, i am logging into an oracle db via sqlplus and running a select statement but i dont know how i can store the results from the sql so i can iterate over it and do more operations over it. I dont want to write a stored procedure with a cursor since i need to... (2 Replies)
Hello,
This is my first post and its because I could not find solution for myself I decided to ask help here.
What I want to do;
I want to get some data from a table 1 on server 1 and insert those datas into a table 2 on server 2. ( lets say schema names are server1 and server 2 also ).... (10 Replies)
I want to represent the columns by whats in a txt file. So the columns.txt file contains "$2$3" and the test.txt file contains "bob tom jones jon"
I have #!/bin/bash
columnsVar=`cat columns.txt`
echo "Columns edited: $columnsVar"
awk ' {print $columnsVar }' test.txt
But it prints out... (1 Reply)
Hi All,
I needed to get the result of two sqlplus queris into shell variables.
After days of looking for the ultimate solution to this problem.. i found this...
sqlplus -s USER/PASS@DB <<EOF | awk '{if(NR==1) printf("%s ", $1); if(NR==2) printf("%s ",
$1);}' | read VAR1 VAR2
set head off... (2 Replies)
I have some HP4+ and HP5 printers printing from Unixware 7.1.4. The problem is that they print a page header with the date and page number. I can't seem to figure out how to stop this. These headers through the pagination off. (2 Replies)
Friends,
I have installed Putty in my windows xp pc. I am connecting the RHEL
AS 3 server using putty from my windows xp. My printer is connected to
my windows xp.
Now, i want to print text.txt of RHEL AS 3.0 in my windows xp printer
through putty.
For Example:
my pc ip is 117.23.2.55... (3 Replies)