Hi Friends,
Do someone know how to capture value in a shell variable from oracle sql?
Requirement : In a table we want to count the number of records and want to pass this value to a shell variable where it can be manipulated later. In ksh shell we open oracle connection from sqlplus.
For example :
sqlplus user/passwd <<EOF
variable v_1 number;
select count(*) into :v_1 from table;
exit
EOF
In a shell variable we want to capture the value of v_1..then what is exact syntex to do it?
Thanks in advance.