9 More Discussions You Might Find Interesting
1. UNIX for Advanced & Expert Users
Hi All,
I have already code to create folder for one country let say US , now we want to create folder/directory for JP country also using shell script , application server.
$COUNTRY='US'
if ]
then
if mkdir -m 777 -p /opt/TEST/$COUNTRY/$INVOICE >/dev/null 2>&1 | tee -a ... (5 Replies)
Discussion started by: Boost
5 Replies
2. Shell Programming and Scripting
Create Dynamic If condition
Hi,
I have a file color.txt which has data as shown below
Red
Blue
Green
Yellow
White
Pink
Black
Based on a variable I execute a tail command as shown below
tail -${LEFT_OVR} color.txt
LEFT_OVR can be any number less than count of number of lines in a... (7 Replies)
Discussion started by: wahi80
7 Replies
3. Shell Programming and Scripting
pattern
tin loop 3
tin xarg 1
tin jim 5
tin icon 2
tin tour 4
patn.out
tin loop 3
tin jim 5
tin icon 1
tin tour 2
while read one two three
do
awk '$2 ~ /'"$two"'/' patn.out || while read four five six
do
awk -v n1=$three -v n2=$six '{BEGIN (n2<n1)?1:0}'
done<patn.out... (3 Replies)
Discussion started by: Roozo
3 Replies
4. UNIX for Dummies Questions & Answers
hey,
just want to ask how to check this scenario
a="apple banana cherry"
if
egg=0
fi
how do you do the condition?
thanks! (2 Replies)
Discussion started by: h0ujun
2 Replies
5. Shell Programming and Scripting
Problem :
I want to create a separate file for country list if condition is true. Please help.
*****************************************************
Input file:
SV-INCR-139302-365540488-201104090934.sqllog
SV-INCR-1082-552793184-201104040805.sqllog
SV-INCR-1077-855045741-201104040805.sqllog... (4 Replies)
Discussion started by: humaemo
4 Replies
6. Shell Programming and Scripting
Hi all,
I have the following code to check the whether the folder is exist in my system.
if ; then echo 'folder exist'; else echo 'folder not exist'; mkdir /home/batch/testing ; fi
When I remove the "testing" folder from "/home/batch" directory, the code is working fine. But when I... (2 Replies)
Discussion started by: suigion
2 Replies
7. UNIX for Dummies Questions & Answers
I am checking one until loop with the following logic
until ||
||||
do
sleep 30
done
before running this i am exporting above variables to SUCCESS.But the loop is running in infinite loop.My requirement is to make the loop run until
all the 3 variables are SUCCESS or any of the 3... (2 Replies)
Discussion started by: dr46014
2 Replies
8. UNIX for Dummies Questions & Answers
Hi guys,
I desperately need your help on my problem:-
I got a folder in my directory that has many files in it. Most of the file's name is starting with certain prefix. Eg: ABC, CDE, EFG, etc. I only want to change file name that is starting from certain prefix and the rest I want them to... (1 Reply)
Discussion started by: balzzz
1 Replies
9. Shell Programming and Scripting
Hi ,
could any one suggest me that how to determine if the first field is numeric and if it is greater than another number then from that point everything else should be printed using awk.
I have tried this
:
awk -v xxxx=$xxxxx '
BEGIN {
enable=0
}
{
print $1
if ( ( $1 !~ "^*$" ... (5 Replies)
Discussion started by: hitmansilentass
5 Replies