Here's one hint:
Using recent version of ksh or bash, you can do this:
Code:
fullname="/home/ 572011 O4MP ORDS 188406 V01 DT 20060608154548.txt"
file="${fullname##*/}"
read _ _ _ dir _ <<<$file
echo $dir
If you have an older version of either ksh or bash, the following works, but is not as aesthitically pleasing (to me

)
Code:
fullname="/home/ 572011 O4MP ORDS 188406 V01 DT 20060608154548.txt"
file="${fullname##*/}"
echo $file| read _ _ _ dir _
echo $dir
Please post back if you run into further problems implementing this...