![]() |
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 |
| split and making an array inside another array | dcfargo | Shell Programming and Scripting | 2 | 08-06-2008 11:07 AM |
| Array inside an array | manas_ranjan | UNIX for Advanced & Expert Users | 5 | 06-10-2008 03:25 PM |
| create array holding characters from sring then echo array. | rorey_breaker | Shell Programming and Scripting | 5 | 09-28-2007 09:42 AM |
| looping a array inside inside ssh is not working, pls help | reldb | Shell Programming and Scripting | 5 | 07-07-2006 11:32 AM |
| inside the JVM | rein | UNIX for Advanced & Expert Users | 1 | 08-05-2005 02:57 PM |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
||||
|
using array inside awk
Hi All,
I have the following code sequence for reading some bulk file and moving the content to two different arrays. while read data do THREEG_PATTERN=`echo $data | egrep "3G"` if [ "$data" == "$THREEG_PATTERN" ] then NEW_THREEG_PATTERN=`echo $THREEG_PATTERN | cut -d " " -f2` THREEG_ARRAY[$IDX]=$NEW_THREEG_PATTERN IDX=$(($IDX+1)) else SP_ARRAY[$IDX_SP]=$data IDX_SP=$(($IDX_SP+1)) fi done < $_pat This code is working perfectly but this is taking long time because of big file size.... How can i improve the performance of this process by using awk or other mechanism? Or how can i convert this entire code to awk? Looking forward ur reply Thanks in advance Subin |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|