how do you write sql queries using shell script
for eg:- we have databae table like EMPNO,ENAME,SAL,DEPTNO
columns in EMP table how you display EMPNO,SAL FIELDS from emp
in SHELL SCRIPT please explain with an example
Answer Posted / nitesh bhope
sqlplus username/userpassword@oracle<<eof
>select * from emp;
>select empno,ename,sal,deptno;
........what ever commands u wanna execute of sql u can
write here
>hit ctrl+d
these are called as here documents
| Is This Answer Correct ? | 11 Yes | 10 No |
Post New Answer View All Answers
Explore about environment variables?
What are "c" and "b" permission fields of a file?
What is the significance of the shebang line in shell scripting?
What will happen to my current process when I execute a command using exec?
how to print the 2-d, 3-d arrays in unix shell script programs please answer thi questio to my mail venusaikumar@gmail.com
Why is the use of shell script?
How do you find out What is your shell?
How can you get the value of pi till a 100 decimal places?
What is the command to find out today's date?
How can the contents of a file inside jar be read without extracting in a shell script?
What is gui scripting?
What does $@ mean in shell?
Rewrite the command to print the sentence and convert the variable to plural: echo “i like $variable”.
What is meant by dos operating system?
Can you write a script to portray how set –x works?