I am trying to write this fn. but dont know how to look for a comma so that the next data can be read in. Any help will be appreciated. Thanks in advance.
#!/bin/ksh
file='/tmp/sid.txt'
typeset -i i=0
while read input
do
IFS=,; set -A arr ${input}
while (( i < ${#arr[@]} ))
do
echo "arr[$i]=${arr[$i]}"
((i+=1))
done
((i=0))
done < "${file}"