![]() |
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 |
| perl-like split function for bash? | eur0dad | Shell Programming and Scripting | 5 | 09-05-2008 06:23 PM |
| Passing global variable to a function which is called by another function | sars | Shell Programming and Scripting | 4 | 06-30-2008 11:39 AM |
| Split a file with no pattern -- Split, Csplit, Awk | madhunk | UNIX for Dummies Questions & Answers | 10 | 12-17-2007 12:57 PM |
| perl split function | new2ss | Shell Programming and Scripting | 5 | 06-08-2006 10:17 PM |
| split function | ktsirig | UNIX for Dummies Questions & Answers | 4 | 09-29-2005 10:58 AM |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
||||
|
awk - split function
Hi,
I have some output in the form of: #output: abc123 def567 hij890 ghi324 the above is in one column, stored in the variable x ( and if you wana know about x... x=sprintf(tolower(substr(someArray[2],1,1)substr(userArray[1],3,1)substr(userArray[4],2,1))) when i simply print x (print x) I get the above output. so it work. I want to make an array of the above output so that each single username (abc123) is stored in a new array . (ex: usrArray[1]="abc123" and usrArray[2]="def567") So I use the split function as: split(x,usrArray,"\n"); well... when I print usrArray[1], instead of just giving me abc123, i get the same results of the variable x, or sometimes different ... any help ? regards |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|