home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #19 / NN_1992_19.iso / spool / comp / unix / question / 10499 < prev    next >
Encoding:
Text File  |  1992-08-29  |  1.2 KB  |  31 lines

  1. Newsgroups: comp.unix.questions
  2. Path: sparky!uunet!zaphod.mps.ohio-state.edu!pacific.mps.ohio-state.edu!linac!uchinews!a-douglas@uchicago.edu
  3. From: a-douglas@uchicago.edu (Allen Douglas)
  4. Subject: AWK Iteration
  5. Message-ID: <1992Aug28.183452.2245@midway.uchicago.edu>
  6. Sender: news@uchinews.uchicago.edu (News System)
  7. Organization: U of C  Law School
  8. Date: Fri, 28 Aug 1992 18:34:52 GMT
  9. Lines: 20
  10.  
  11. Hello,
  12. I need to get the shell or awk to take a large file and pipe segments 
  13. to a temporary file where I can then run some awk or agrep commands 
  14. (on the temporary file.)   The file is a collection of legal cases, 
  15. delimited by "of 38 CASES" I want to awk/agrep the individual cases 
  16. and output to a results file.
  17.  
  18.  
  19. The logic is: 
  20.  
  21. Read in to beginning of first break point (case)-(this output will be discarded)
  22. Start reading the first case until beginning of next case and send text of case to temporary file .
  23.        Process commands on temp file, output to results file(s.)
  24. Read in text of the next case, until the begining the next+1 case.    (replacing the previous output)
  25.  
  26. The cases (as in legal case) have delimeters of "of 38 CASES" 
  27.  
  28.  
  29. I haven't been able to fathom the syntax, as I am very green programming Unix. 
  30.  
  31.