The UNIX and Linux Forums
>
Top Forums
>
Shell Programming and Scripting
Need some sort of loop
.
User Name
Remember Me?
Password
google unix.com
Forums
Register
Forum Rules
Links
Albums
FAQ
Members List
Calendar
Search
Today's Posts
Mark Forums Read
Thread
:
Need some sort of loop
View Single Post in the UNIX and Linux Forums - Click on the Thread or Permalink to View Entire Thread -->
#
6
(
permalink
)
04-28-2008
radoulov
addict
Join Date: Jan 2007
Location: Варна, България / Milano, Italia
Posts: 2,926
Like this?
Code:
awk '!_[$2]++{ printf "data_2_%d = new Option(\"%s\",\"%s\");\n", ++c, $2, $2 }' file
Last edited by radoulov; 04-28-2008 at
12:20 PM
.. Reason: corrected
radoulov
View Public Profile
Find all posts by radoulov
Find radoulov's past nominations received
Find radoulov's present nominations given