Search the web
Sign In
New User? Sign Up
geeksthatgawk · for GNU Awk questions & discussions
? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Want to share photos of your group with the world? Add a group photo to Flickr.

Best of Y! Groups

   Check them out and nominate your group.

Messages

  Messages Help
Advanced
Messages 90 - 121 of 221   Oldest  |  < Older  |  Newer >  |  Newest
Messages: Simplify | Expand   (Group by Topic) Author Sort by Date ^
90
Hi, I would to do this in a gawk script: BEGIN { as="188.772.11.11" while (getline <"../datas"){ split($0,s,";") if(/$as;/) { print $0 } } } but it fails. Of...
bruno_bury
Offline Send Email
Dec 4, 2003
11:08 am
91
Try if ( $0 ~ as ) { print $0 } In general, once you stuff a regular expression into a variable, you cannot use the / / syntax--that's only for literal regular...
Albert Bickford
albert_bickford
Offline Send Email
Dec 5, 2003
2:02 am
92
Hi Thanks for answering - I kinda desperate! I have something like that: for i in $(ls *); do #here it is for files in a loop sed '/something/,/something/d' $i...
uhg_kwant
Offline Send Email
Dec 9, 2003
10:33 pm
93
Hi ya Urszula Hope you're well. It doesn't seem that complex. Are your lines: u> -3.085902 (1a) u> -0.40908 (2a) u> 1.968368 (3a) u> -3.79142 (4a) u> -3.79142...
William
chiron_sun
Online Now Send Email
Dec 28, 2003
12:47 am
94
Hi Bruno... I'm confused. If you are asking about awk, there's no $. 'as' I take it is a string RegExp ? Well, "." is a meta-character, or special character....
William
chiron_sun
Online Now Send Email
Dec 28, 2003
1:05 am
95
Suppose you want to do something like this: cat file1 | gawk -f script.awk file2 file3 file4 How do you handle this? gawk (GNU Awk 3.1.1) seems to skip over...
jason_quinn
Offline
Apr 9, 2004
9:45 pm
96
... Some UNIX/LINUX utilities allow you to include "-" by itself among a list of filenames on the command line as an indication to read the standard input ...
Albert Bickford
albert_bickford
Offline Send Email
Apr 9, 2004
11:56 pm
97
Where can I get an interpreter for Windows 2000 so that I can run gawk?...
goodmis
Online Now Send Email
Apr 27, 2004
1:34 pm
98
See GNU project on Sourceforge.net ... From: goodmis To: geeksthatgawk@yahoogroups.com Sent: Tuesday, April 27, 2004 11:33 PM Subject: [Geeks that Gawk] Need...
* William
chiron_sun
Online Now Send Email
Apr 27, 2004
1:50 pm
99
Thanks William, I downloaded UnDows and it was just what I needed. I have to admit I am a little rusty on my French. Thanks Again Jason Give me (G)awk and I...
Jason McGee
goodmis
Online Now Send Email
Apr 28, 2004
2:47 pm
100
It's a pleasure Jason Did you get what you wanted ? The real gawk is on the GNU list http://sourceforge.net/project/showfiles.php?group_id=23617 with all the...
* William
chiron_sun
Online Now Send Email
Apr 29, 2004
2:45 am
101
I am running UnDows and I would like to use a switch statement. Is this possible? switch ($1) { case 1: printf("%s\n", $1) case 2: printf("%s\n", $2) } ...
goodmis
Online Now Send Email
Apr 29, 2004
5:51 pm
102
I don't think there is a switch statement in (g)awk. In this situation, I've always used the following construct: if ( ) { } else if ( ) { } else { } --Albert...
Albert Bickford
albert_bickford
Offline Send Email
Apr 29, 2004
7:12 pm
103
Thanks Albert, I saw something about a switch in some gawk documentation. NOTE: This subsection describes an experimental feature added in gawk 3.1.3. It is...
goodmis
Online Now Send Email
Apr 29, 2004
8:03 pm
104
I have to agree with the earlier post. switch(. <var> ){ case <const> ... } Is a terse version of if-else if-else if phrasing. From gawk 3.1 User Manual: ...
* William
chiron_sun
Online Now Send Email
Apr 30, 2004
6:46 am
105
Is there a way that I can implement Interactive Commands? Instead doing this by hand. Enter Name: Jason <return> Do you want to continue? Y <return> Can I put...
goodmis
Online Now Send Email
May 22, 2004
11:39 am
108
Hi, Could anyone here share a wrap function? something like: function wrap(long_line, columns) { ... } Daniel...
Daniel Ajoy
daniel_ajoy
Offline Send Email
Jul 28, 2004
1:51 am
109
Hello, Have several shell scripts, that issue sed and awk commands that have worked will for years on SCO Unix. We are moving our application to a new Redhat...
barryshadduck
Offline Send Email
Sep 2, 2004
5:55 pm
110
... have ... to ... Hello Again, Found that shell scripts and awk programs work fine. It was just the transfer process that added something to each end of...
barryshadduck
Offline Send Email
Sep 3, 2004
7:14 pm
111
I have a set of files that need to have a number assigned to $3 for each record, but if the record has the same value in $2, the value in $3 must stay the same...
d_godfrey2000
Online Now Send Email
Sep 7, 2004
9:21 pm
112
In order to achieve what you give in your example, I would suggest this: BEGIN {FS="|"; OFS="|"; last="";} { if ($2 != last) { last = $2 line++; } $3 =line; ...
Albert Bickford
albert_bickford
Offline Send Email
Sep 9, 2004
1:13 am
113
pl. help. I have large data files that separated by numeric file extensions. I need t process them in order and compile the necessary info. What is the best...
shahjb40
Offline Send Email
Sep 9, 2004
1:51 am
114
I have used gawk for similar applications. Since it processes files sequentially, it can handle very large files. The only significant limits are the speed...
Albert Bickford
albert_bickford
Offline Send Email
Sep 9, 2004
2:26 am
115
Here is the file structure. The file name, for example could be EPAXXXXX.001 The extension (file type) can range from “.001” to “.124”. There can...
Jagdish Shah
shahjb40
Offline Send Email
Sep 9, 2004
5:56 pm
116
... Thanks Albert! Your solution works great. I did have to change it to fit my actual file format - here are a few lines (bear with me - I'm showing the REST...
Don Godfrey
d_godfrey2000
Online Now Send Email
Sep 9, 2004
6:29 pm
117
Okay, so it sounds like you've got two different counters which vary independently, which are embedded in the file names. So, one way to accomplish that would...
Albert Bickford
albert_bickford
Offline Send Email
Sep 11, 2004
12:48 pm
118
From what you've said below, it sounds like you've handled things more or less the way I would have done it. Perhaps there is a more elegant way, but one of...
Albert Bickford
albert_bickford
Offline Send Email
Sep 11, 2004
12:48 pm
119
... The reason I was trying to do it in one script, was for speed - I'm processing about 1 million records each time I run it, and doing quite a few other...
Don Godfrey
d_godfrey2000
Online Now Send Email
Sep 11, 2004
4:54 pm
120
... few ... I'm afraid I don't know that. You might have to do some testing to find out. I was speaking before from the perspective of optimizing development...
Albert Bickford
albert_bickford
Offline Send Email
Sep 12, 2004
1:19 pm
121
With help of someone, for my immediate need, I was able to do the following and was able to process the files. #! /bin/bash for ( j = 1; j < 125; j++ ); do ...
Jagdish Shah
shahjb40
Offline Send Email
Sep 13, 2004
5:36 pm
Messages 90 - 121 of 221   Oldest  |  < Older  |  Newer >  |  Newest
Advanced
Add to My Yahoo!      XML What's This?

Copyright © 2007 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines - Help