On Tuesday 21 November 2006 14:41, Kevin Donnelly wrote:
On Wednesday 15 November 2006 00:57, Anders Johansson wrote:
oops, forgot to actually read something. How about declare -a foo while IFS=':' read -a foo; do echo user ${foo[8]} has password ${foo[9]} done < user_pw.csv
Thanks to you and Randall. Unfortunately, neither of these worked (I was entering the various suggestions on one command-line, but that shouldn't really make a difference, should it?). In the event I just added the info by hand. I'll have to look into awk in more detail.
It works, I actually tried it before I sent it. On a single command line, it would look like while IFS=';' read -a foo; do echo user ${foo[8]} has password ${foo[9]}; done < user_pw.csv When you tried it, did you make sure you typed everything correctly? Don't bother with awk for simple things like this, as my example above shows, bash can do it all far simpler and easier -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org