Hi,
Have to check file names in some given directory.
SO, What is the right syntax here:
*$3*=="'$object_list'" - just wanted to check if $3 is in the object_list.
And also, Do I need so many quotes around?
Hi,
Have to check file names in some given directory.
SO, What is the right syntax here:
*$3*=="'$object_list'" - just wanted to check if $3 is in the object_list.
And also, Do I need so many quotes around?
why are you using * around $3 ?
The syntax is correct if you remove the * like
file_list=`ls $DATA_PATH | awk -F"_" 'NF==5 && $1=="'$vendor'" && $2=="'$source'" && $3=="'$object_list'" {print $0}'`
object_list="CUSTOMER ADDRESS TELEPHONE"
Here I wanted to check if $3 is in the object_list, not equal, but part of it.
For instance if $3="CUSTOMER" - OK.
So I need something like IN or *$3* syntax, I think.
thanks.
Please can u tell me how to post a new thread? i am new user here, i am not finding any link to do so! please help me...
To the OP: use ~ for contains rather than == (use nawk / /usr/xpg4/bin/awk on solaris)
To the thread hijacker
, shruthinagaraj, go to a particular forum where you wish to post - in the top left is a "start new thread" button...
Is it ok to do it that way:
I can't do:
But I can
for some reasons?