Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!know!sdd.hp.com!hplabs!hpcc05!hpdmd48!oscarh From: oscarh@hpdmd48.boi.hp.com (Oscar Herrera) Newsgroups: comp.unix.shell Subject: Re: line length limit in awk Message-ID: <8720005@hpdmd48.boi.hp.com> Date: 10 Oct 90 14:33:18 GMT References: Organization: Hewlett Packard - Boise, ID Lines: 24 |Is the limitation of number of fields per record in (n)awk insurmountable? |My data files consist of a julian date in "%13.5f " format followed |by 100 data readings in " %8.2f" format, followed by a newline. Pretty |tame stuff, but awk, nawk and vi all claim the lines are too long to |deal with. Other tools have varying success. Am I screwed or is |there and easy way to fix awk? (Without a source license.) I've run into similar problems in the past but have been able to 'work around' the limitations by combinations of the fold command and by redefining the record separator awk uses. Of course it is always easier if the data a files are preformatted by whatever process produces it with the post processing by awk in mind. Here is an example of a reformatted record. In the BEGIN part of your awk script you would redefine the record separator to # 1234567890123.12345 12345678.12 . . . 12345678.12 12345678.12 #