OK, a bit more detail:

We have a report generated by 3rd-party software, from a big vendor with
lots of customers. We want to extract some of the text from the report and
generate a new report (using an overlay). To get the 3rd party vendor to
make a change is a big deal, costing lots of cash and taking at least a
month. As an 'independent' contractor, I can do it way faster and for a
whole lot less.

With *SCS files, I might CPYSPLF to copy it to a 133 record length file
(called 'SPOOLFILE'), write up a quickie program to build a new spoolfile,
printing what I need from the original and apply the overlay.

So... now I need to do this same process on an *AFPDS type of spoolfile.

Tom


-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx
[mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of Terrence Enger
Sent: Friday, October 23, 2009 3:21 PM
To: Midrange Systems Technical Discussion
Subject: Re: CPYSPLF and AFPDS

On Fri, 2009-10-23 at 14:17 -0500, Tom wrote:
We're on v5r2. I need to copy an AFPDS spoolfile to a db file, which will
then be accessed within an RPG program. I've tried CPYSPLF, but the
system says it can't do it.



Any ideas?

Tom,

The only idea which jumps out from infocenter-- but somebody here may
know better--is the set of APIs Open Spooled File (QSPOPNSP), Get
Spooled File Data (QSPGETSP), and Close Spooled File (QSPCLOSP) API.
How you map the data in a df file is up to you; I know of no such thing
as a standard mapping.

In the past, I have looked at these APIs only deeply enough to be
encouraged to invent another solution to the problemn at hand. OTOH,
there more doubtless more examples now that when I last cared, google is
better now than when I last cared, and so forth.

Depending on the nature of your spool files and what you want to extract
from them, you may not need to parse the whole AFPDS language. If you
care to tell us about your goal, the people here may be able to suggest
and alternative solution.

Please let us know how you get on.

Cheers,
Terry.



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2021 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.