In the above file I want to replace column 2 with a value extracted from database
like (select student_id from stud_master)
ahem - yes? From a select statement like the above you likely get a list in return, say, this:
What exactly do you want to do to "column two" and what has has this to do with the list the select-statement returned? Could you show an example of the outcome you have in mind?
Quote:
Originally Posted by kev94
Normally I could able to connect to db and and get the value.
Now I want to know to call a oracle function and replace the output for $2 variable.
Now i am even more confused: if you replace "$2" (the second field) with the output i envisioned above you would get this:
I suppose this is not what you want, but i can't figure out what it actually is. Please enlighten us.
hi,
I just started to work on unix,
I was wondering if it is possible to call a c++ function from a script.
now, i don't mean starting a program, i mean dynamicaly calling a funtion (like working with a dll)
thanks (3 Replies)
Hi folks,
I'm just running through an oreilly korn shell book but have witnessed an output difference on my own unix machine and the output provided in the book. Can anyone help?
create a script called ascript as follows:
function afunc {
print in function $0: $1 $2
var1="in... (16 Replies)
Hi,
Can we define a function say func1 in a script 1.sh and call this function from another script say 2.sh by passing an argument :confused: (2 Replies)
:confused:Hi ,
I have a script as shown below:
rpttxt()
{
name="$*"
awk '/'"${name}"'/ {print $2 $3"=" $4}' file.txt
}
xx = rpttxt "COL_HEAD_1"
awk 'BEGIN {printf("%36s \n ","'"$xx"'")}'
rpttxt() is a function..I want to store the final result of this function in... (3 Replies)
i have a function defined in one ksh (ksh 1)
i want to use that function in another ksh (ksh 2)
i am using
. $<directoryname>/<ksh name>
i am calling the function defined in ksh 1 in ksh 2
i want the returnstatus from the above operation
but it is not executing the function
what i... (1 Reply)
Dear Sir/Madam,
I use the following way to call the oracle stored procedure in a perl script, but I do not know how to call a oracle function by the following way ?
# ARGV is the oracle stored procedure name with parameters
$str = "sqlplus -s <<-eof \n" .
"$db_login... (0 Replies)
This is my function which is creating three variables based on counter & writing these variable to database by calling another function writeRecord
but only one record is getting wrote in DB.... Please advise ASAP...:confused:
function InsertFtg
{
FTGSTR=""
echo "Saurabh is GREAT $#"
let... (2 Replies)