![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| sed string manipulation | speedieB | Shell Programming and Scripting | 4 | 11-23-2008 08:27 PM |
| string manipulation | james6 | UNIX for Dummies Questions & Answers | 5 | 06-03-2008 10:05 AM |
| String Manipulation Help | shadow0001 | Shell Programming and Scripting | 4 | 03-09-2008 04:35 PM |
| string manipulation | Cactus Jack | Shell Programming and Scripting | 9 | 02-14-2008 01:14 PM |
| awk string manipulation | zoo591 | Shell Programming and Scripting | 2 | 08-09-2006 12:13 PM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
||||
|
string manipulation
Hello,
I have a korn shell string variable str1 = "A,B,Z" I would like to create another korn shell string variable str2 = "letter = 'A' or letter = 'B' or letter = 'Z' " Please help! Thanks in advance an UNIX newbie! |
|
||||
|
Code:
eval `echo $str1 | awk -F, '{
for (i =1; i <= NF; i++)
printf("a[%d]=%s\n",i,$i);
}'`
|
| Sponsored Links | ||
|
|
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|