10 More Discussions You Might Find Interesting
1. UNIX for Beginners Questions & Answers
Hello ,
Im calling every single file inside my script like 1.sql,2.sql so on it looks so tedious. I want to replace with for loop where every file gets executed. When i use for loop im getting errorUnexpected EOF] , can anyone please help me out in this..
How i can use for loop to invoke my... (6 Replies)
Discussion started by: preethi87
6 Replies
2. UNIX for Dummies Questions & Answers
I need to connect a databas eusing sqlplus and i need to store the results of each query in separate file.
is it possible to achieve this usng single sqlplus?
i dont want to connect each time for each query.
thanks (3 Replies)
Discussion started by: pandeesh
3 Replies
3. Shell Programming and Scripting
Hi,
Could someone tell me how to stop SQLPLUS command from printing the connection details in the console.
Below is the lines i get in console when executing the sqlplus...
SQL*Plus: Release 10.2.0.1.0 - Production on Wed Mar 9 03:31:03 2011
Copyright (c) 1982, 2005, Oracle. All rights... (2 Replies)
Discussion started by: funonnet
2 Replies
4. Shell Programming and Scripting
Hi!
I would like to do a single connection to sqlplus and execute some querys.
Actually I do for every query one connection to database
i.e
echo 'select STATUS from v$instance;
exit' > $SQL_FILE
sqlplus user/pass@sid @$SQL_FILE > $SELECT_RESULT
echo 'select VERSION from v$instance;... (6 Replies)
Discussion started by: guif
6 Replies
5. Shell Programming and Scripting
Hi,
I am using sqlplus query to get results in a csv format in unix. I am using ksh, and below is the query.
echo "select r.num|| ',' || p.path ||',"' || r.issue_description ||'",' ||p.timestamp from events r, messagepath p;">> $QUERY_FILE
sqlplus -s $LOGIN @ $QUERY_FILE>>$OUTFILE
... (2 Replies)
Discussion started by: Nutan
2 Replies
6. Programming
Is there anyway to spool my select statement into spool files of max 10000 records each?
eg I have a select statement that will return 45000 records.
A normal spool command will output the 45000 into just one spool file.
How can I make sqlplus do this?
00001 - 10000 records --- spool... (3 Replies)
Discussion started by: Leion
3 Replies
7. UNIX for Advanced & Expert Users
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)
Discussion started by: pranavagarwal
2 Replies
8. Shell Programming and Scripting
Hi to all,
I have a endday.sh file. And I execute this like "sh endday.sh" from command prompt. In endday.sh file it writes:
sqlplus temp/temp@data @run.sql&
echo $!>>pid.txt
However my aim is not to put the pid into pid.txt but I need to insert the pid into an oracle table using sqlplus.... (1 Reply)
Discussion started by: maverick1234
1 Replies
9. UNIX for Advanced & Expert Users
Hi to all,
I have a endday.sh file. And I execute this like "sh endday.sh" from command prompt. In endday.sh file it writes:
sqlplus temp/temp@data @run.sql&
echo $!>>pid.txt
However my aim is not to put the pid into pid.txt but I need to insert the pid into an oracle table using sqlplus.... (1 Reply)
Discussion started by: maverick1234
1 Replies
10. Programming
Hi to all,
I have a endday.sh file. And I execute this like "sh endday.sh" from command prompt. In endday.sh file it writes:
sqlplus temp/temp@data @run.sql&
echo $!>>pid.txt
However my aim is not to put the pid into pid.txt but I need to insert the pid into an oracle table using sqlplus.... (1 Reply)
Discussion started by: maverick1234
1 Replies