i='$MY_TEST/my_file_name.dat '
echo $i
FILE_DIR=`echo $i | nawk '{print toupper(substr ( $1,match($1,"$"
+1, match($1,"/" )))}'`
echo "FILE DIR $FILE_DIR "
Thats the script and what I want to do is match the occurance of the dollar sign. But it dosent match and there is no error message as well.
So I want the programme to return the string $MY_TEST
I tried to escape the dollar sign with a backslash (\) but didnt work.
Any help appreciated.
Thanks
echo $i
FILE_DIR=`echo $i | nawk '{print toupper(substr ( $1,match($1,"$"
echo "FILE DIR $FILE_DIR "
Thats the script and what I want to do is match the occurance of the dollar sign. But it dosent match and there is no error message as well.
So I want the programme to return the string $MY_TEST
I tried to escape the dollar sign with a backslash (\) but didnt work.
Any help appreciated.
Thanks