[HPADM] Script question to make multiple file of fixed rec len of 255

From: Lal, Neeraj (Neeraj.Lal@pfizer.com)
Date: Thu Sep 11 2003 - 18:18:58 EDT


Hi Admins

Here is the small question for scripting

In a dir I receive files on daily basis the no of file is not fixed it may
02 or 100 but the file name prefix & Suffix is Standard
Which is PCHC_(-Some unique no-).EDI

Every File has some records with 255 rec length and some records 455 I have
to make all the files of same rec len which is 255.

For a single file I can use the follwing script

awk </medicaid/prod/edi/PCHC_0023.EDI \

'
 {
 x1=substr($0,1,255);
 print x1;
 }
 '

How should I process the multiple file ?

Neeraj Lal
Pfizer Inc.
Consultant CHC-IS
973-385-2734

--
             ---> Please post QUESTIONS and SUMMARIES only!! <---
        To subscribe/unsubscribe to this list, contact majordomo@dutchworks.nl
       Name: hpux-admin@dutchworks.nl     Owner: owner-hpux-admin@dutchworks.nl
 
 Archives:  ftp.dutchworks.nl:/pub/digests/hpux-admin       (FTP, browse only)
            http://www.dutchworks.nl/htbin/hpsysadmin   (Web, browse & search)


This archive was generated by hypermail 2.1.7 : Sat Apr 12 2008 - 11:02:33 EDT