msg files aren't any more variable-length than any other files, but i agree
that would be a problem.
for this question, let's say the records are fixed length? they could be
made so in reality but not as easily as writing cobol;-)
i think suprtool won't work because you can't build the loop you need. i
think.
but maybe you can build the loop in jcl, something like
file msg1=msg1;msg
file msg2=msg2;msg
while 1 = 1 do
supr cmd="def switch,msg1,1,1;in *msg1;if switch='y';o *msg2;exit"
endif
will that work? i can't try it but iirc supr may be too smart & will
complain.
> -----Original Message-----
> From: Francois Desrochers [mailto:[log in to unmask]]
> Sent: Wednesday, March 09, 2011 1:02 PM
> To: tracy pierce; [log in to unmask]
> Subject: RE: [HP3000-L] Message file question
>
> Unfortunately, Suprtool only deals with fixed-length records. MSG files
are
> variable-length.
>
> François
>
> -----Original Message-----
> From: HP-3000 Systems Discussion [mailto:[log in to unmask]] On Behalf
Of
> tracy pierce
> Sent: Wednesday, March 09, 2011 3:49 PM
> To: [log in to unmask]
> Subject: Re: [HP3000-L] Message file question
>
> best mechanism i've seen for this involves two message files; in your case
>
> the first msg1 is fed by netbase like it is now;
>
> it gets read by myfilter, and (maybe) written to the second msg2.
>
> the second needs a new name, so you have to change the file reference on
the
> receiving process from msg1 to msg2.
>
> now just write myfilter, a very simple program to reject the recs you
don't
> like; you can let it run continuously in a job. better control would be
> nice of course, but if you shutdown/startup the system in the proper
> sequence, none's needed just be sure myfilter can't be active when its job
> is killed. myfilter is very straightforward, doesn't even need to know
it's
> dealing with msg files. cobol works fine:
>
> open input msg1 output msg2
> perform until 1 = 2
> read msg1
> if raining and sunny
> write msg2 from msg1
> endif
> end perform
> exit
>
> (can it be done with suprtool?)
>
>
> !job dbfilter,whoever.whatever;outclass=lp,1
> !file msg1;msg
> !if notexist msg1
> ! build it
> !endif
> !file msg2;msg
> !if notexist msg2
> ! build it
> !endif
> !run myfilter
> !eoj
>
>
>
> Tracy Pierce
>
>
>
> > -----Original Message-----
> > From: HP-3000 Systems Discussion [mailto:[log in to unmask]] On
Behalf
> Of
> > Simpkins, Terry
> > Sent: Wednesday, March 09, 2011 9:29 AM
> > To: [log in to unmask]
> > Subject: [HP3000-L] Message file question
> >
> > We use NETBASE to shadow our Production databases to a 'backup' HP3000.
> > We also use Bridgeware from Taurus to 'shadow' the data to SQL versions
> > of the IMAGE database onto a Windows machine. NETBASE uses message
> > files to transmit the IMAGE database changes to Taurus who then performs
> > the SQL changes (puts, changes & deletes). From time to time, I need to
> > 'manipulate' the message file records going to Taurus. Specifically I
> > need to find and delete certain records in the message. These records
> > could (certainly are) intermixed throughout the message file.
> >
> >
> >
> > My question is what tools can I use to 'edit' a message file without
> > destroying the file?
> >
> > I learned today (the hard way) that using FCOPY to copy from a message
> > file, destroys the records read from the message file. Can you "COPY" a
> > message file without destroying the records that are copied?
> >
> >
> >
> > Terry W. Simpkins
> >
> > Director Business Systems
> >
> > Measurement Specialties, Inc.
> >
> > office: +1 757-766-4278
> >
> > mobile: +1 757 532-5685
> >
> > [log in to unmask] <mailto:[log in to unmask]>
> >
> > www.meas-spec.com <http://www.meas-spec.com>
> >
> >
> >
> >
> > * To join/leave the list, search archives, change list settings, *
> > * etc., please visit http://raven.utc.edu/archives/hp3000-l.html *
>
> * To join/leave the list, search archives, change list settings, *
> * etc., please visit http://raven.utc.edu/archives/hp3000-l.html *
* To join/leave the list, search archives, change list settings, *
* etc., please visit http://raven.utc.edu/archives/hp3000-l.html *
|