10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi folks,
I have a scenario to convert the update statements into insert statements using shell script (awk, sed...) or in database using regex.
I have a bunch of update statements with all columns in a file which I need to convert into insert statements.
UPDATE TABLE_A SET COL1=1 WHERE... (0 Replies)
Discussion started by: dev123
0 Replies
2. Shell Programming and Scripting
Hello All,
I have 2 different pieces of code, I am confused why the Code1 is giving me the correct result where as the Code2 is not giving me correct result. It gives me always result as "Failure" irrespective of the "ERROR" word exists in logfile or not. may I know the reason why? I am using Bash... (17 Replies)
Discussion started by: Ariean
17 Replies
3. Shell Programming and Scripting
Hi,
I have an array with characters and I am looking for specific character in that array and if those specific character not found than I use goto statment which is define somehwhere in the script. My code is:
set a = (A B C D E F)
@ i = 0
while ($i <= ${#a})
if ($a != "F" || $a != "D")... (3 Replies)
Discussion started by: dixits
3 Replies
4. Shell Programming and Scripting
Please see the script segment below
for i in $files
do
echo $i
if ; then
case "$1" in
"IE0263"|"IE0264"|"IE0267"|"IE0268")
short_filename=`ls -l $i | cut -c108-136 | sort`
;;
"IE0272"|"IE0273")
short_filename=`ls -l $i | cut... (4 Replies)
Discussion started by: jmahal
4 Replies
5. Shell Programming and Scripting
Hi All,
Please can somebody advise that if I want to search a pattern xyz the grep command should only select xyz and not any other pattern containing xyz (ex abxyzcd)
Regards (1 Reply)
Discussion started by: Shazin
1 Replies
6. Shell Programming and Scripting
Okay, well this is more or less my first attempt at writing a shell script.
Anyways, here's my code:
cd ${PATH}
if
then
rm ${FILE}
./anotherScript
else
exit 1
fi
exit 1
Anyways, it's a pretty simple script that is supposed to search for the... (4 Replies)
Discussion started by: cbo0485
4 Replies
7. UNIX for Advanced & Expert Users
Hi -
I have file which contains high bit unicode chars like © etc.. How can I do grep to find out lines which contain copyright symbol ©
I tried using
grep \x{00A9}
grep \x\{00A9\}
Thanks- (7 Replies)
Discussion started by: ayyo1234
7 Replies
8. Shell Programming and Scripting
Can somebody please guide me towards right syntax:
#!/bin/ksh
if i = $(grep $NAME filename)
echo "Name Found"
else
echo " Name not Found"
fi
I need to grep for $NAME in the file, and if it returns false, execute a series of commands and if true, exit out.
The above is not the right... (3 Replies)
Discussion started by: chiru_h
3 Replies
9. HP-UX
Hi I need to check if the following patches are installed in a HP-UX machine "GOLDQPK11i, which in turn includes both GOLDAPPS11i and
GLODBASE11i
How can I go about doing it, am still a struggling sys admin!
Saw this command showrev -p but command not found in the machine thou!
Thanks... (3 Replies)
Discussion started by: gelbvonn
3 Replies
10. UNIX for Dummies Questions & Answers
Can anyone define the following for me?
/etc/rc.c/init.d/iptables restart
Our resident "Geek" is giving away a prize if I can tell him what this means. (5 Replies)
Discussion started by: txyzzy
5 Replies