10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi,
I have some 2000 names in a table like below.
Java
Oracle/SQL
ANSI SQL
SQL,DWH,DB
DB&Java
And by using for loop in my code i am able to get a single word but if there is any special character or space then it is considering as a next line.
I have to execute the below queries in... (10 Replies)
Discussion started by: Samah
10 Replies
2. Shell Programming and Scripting
I'm looking to write a script that takes a .txt filename as an argument, reads the file line by line, and passes each line to a command. For example, it runs command --option "LINE 1", then command --option "LINE 2", etc. I am fetching object files from a library file, I have all the object file... (2 Replies)
Discussion started by: Paul Martins
2 Replies
3. Shell Programming and Scripting
Hi friends,
Need your help again to get a best approach for the below scenario.
I am previously having one shell script which accepts request_id/s as the command line argument.
single req_id arg= 1111
Multiple arg= 1111,2222,3333
which gets passed to the embedded sql inside to... (9 Replies)
Discussion started by: Showdown
9 Replies
4. Shell Programming and Scripting
Hi All,
I am new to shell script. I am trying to pass value from .sh file to .sql file .
But I am able to run the .sql file from .sh file with values in sql file.
But I am unable to pass the values from .sh file. can some one please help to resolve this.
here is my .sh file
s1.sh
... (4 Replies)
Discussion started by: reddy298599
4 Replies
5. Shell Programming and Scripting
Hi,
i wan't to pass a shellscript variable to a sql file.
a.sql
select $field from dual;
the way i am calling this is through sqlplus
field_name="sysdate"
sqlplus -s username/password@hostname:port/servicename <<EOF
@a.sql $field_name
EOF (4 Replies)
Discussion started by: reignangel2003
4 Replies
6. UNIX for Dummies Questions & Answers
I need a bit of explanation:
LogFile=${LOGS_DIR}/${1}_$$
I know:
- LOGS_DIR is an environment variable
- $$ is the PID
... but what is ${1} ?? Is it another method to access a command line variable, or the job name?
Thanks!
Jon (3 Replies)
Discussion started by: jdorn001
3 Replies
7. UNIX for Dummies Questions & Answers
Hi all ,
I want to pass contents from a file say f1 as arguments to a sql query which has In statement using a script
example
select * from table_1 where login in ( `cat f1`) ;
will this work or is there any other way to do it. (1 Reply)
Discussion started by: zozoo
1 Replies
8. Shell Programming and Scripting
My shell script generates a bunch of lines of text and passes this text as an argument to a perl script.
I'm able to do this, but for some reason newlines don't get recognized in the perl script and so the script just prints actual '\n' instead of carriage returning, otherwise everything gets... (3 Replies)
Discussion started by: stevensw
3 Replies
9. Shell Programming and Scripting
Hi,
Please guide to pass an array as a arg to a script...
for example,
I have a script small.sh to find the small no of given arg as below...
#! /bin/sh
# this script is for finding the small number
set -A arr_no_updates
small=$1
i=1
for arr in $@
do
if (3 Replies)
Discussion started by: little_wonder
3 Replies
10. Shell Programming and Scripting
Hi friends,
I am trying to pass input from command line and trying to print that column values. (FYI: I am using ksh) My code goes like this...
#!/bin/sh
column=$1
awk '{print $'$column'}'
I execute using command like this --> ls -l | file_name parameter
Hope I am clear with my... (2 Replies)
Discussion started by: divzz
2 Replies