dove17
04-04-03, 05:17
| Hi, I have this peice of code that does not work on SunOS. Can anyone tell why? #! /bin/sh showdate=05042003 echo $showdate aday="`expr ${showdate:0:2}`" echo "day is $aday" exit 0 if i do it from command line like bash$ >showdate=05042003 bash$ >aday="`expr ${showdate:0:2}`" bash$ >echo $aday 05 i get correct answer but it does not work in script. all answers are welcome. dove17 |