10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I have a a file which contains an oracle query. If this file is pushed into a shell script such as the below, it of course works fine.
su - oracle -c 'sqlplus -s / as sysdba <<EOF
What i am after... (2 Replies)
Discussion started by: nms
2. UNIX for Beginners Questions & Answers
I am having command to run which will take argument as input file. Right now we are creating the input file by cat and executing the command
ftptransfer -i input file
cat >input file
Is there a way I can do that in a single command like
... (1 Reply)
Discussion started by: arunkumar_mca
3. Shell Programming and Scripting
I'm trying to do a "simple" thing.
grep -rls grepped_exp path | xgs
where xgs is an alias to something like:
xargs gvim -o -c ":g/grepped_exp"
now the problem is that I want to pass the "grepped_exp" to the piped alias.
I was able to do something like what I want without the... (4 Replies)
Discussion started by: hagaysp
4. Shell Programming and Scripting
How to pass the alphabet character as a argument in case and in if block?
if a-z ]]
case $1 in
a-z) echo "the value is a alphabet"
edit by bakunin: please use CODE-tags. We REALLY mean it. (9 Replies)
Discussion started by: Roozo
5. Shell Programming and Scripting
I have a script that is scheduled with cron and runs every night. The cron part looks like this:
00 20 * * 0,1,2,3,4,5,6 /usr/local/bin/BACKUP TBTARM HOT DELETE
My issue is with the 3rd parameter. Somewhere in the script, i want to tell the script to delete some files if the 3rd... (7 Replies)
Discussion started by: dollypee
6. UNIX for Dummies Questions & Answers
Need help for the following scenario.
I am having two directories /tmp/a and /tmp/b. /tmp/a again has subdirectories /tmp/a/aa and /tmp/a/ab.
I want to run a script from /tmp/b to search for a file user.lst in the folders /tmp/a/aa and /tmp/a/ab, if available, i want to make a file in... (3 Replies)
Discussion started by: sudeep.id
7. Shell Programming and Scripting
For some reason I'm NOT seeing "teststring" when I type: ./test.sh "echo $test"
Any ideas on how to get around this?
I've tried commands like:
./test.sh "echo $($test)"
./test.sh "echo '$test'"
And many variations to no... (6 Replies)
Discussion started by: secops
8. UNIX for Dummies Questions & Answers
Howto view gzipped files with name file.gz.$DATE on a Solaris box (without unzipping first)
$ ls -lrt
-rwxrwxr-x 1 oracle dba 569745 Apr 4 19:45 4_person2profileCon.txt.gz.04.04.11*
-rwxrwxr-x 1 oracle dba 3783 Apr 4 19:45... (4 Replies)
Discussion started by: slashdotweenie
9. Shell Programming and Scripting
i have script like below..
echo "1) first option"
echo "2) second option"
echo "*) please enter the correct option"
case $select in
1) echo "first option selected"
2) echo "second option selected"
*) echo "please enter the correct... (4 Replies)
Discussion started by: Shahul
10. UNIX for Dummies Questions & Answers
this is the only way i can think of to do this but there must be a better way or else im gonna end up writing 200 lines of copy and pasting code.
echo ' READ WRITE EXECUTE'
own=$(ls -al $1 |cut -c2)
if ($own==r) then
Im writing a... (1 Reply)
Discussion started by: iago