Don't think you can change the Order (RRN) of an Arrival Sequence File. But if you wanted to do it using 2 files and SQL, this works:


Assuming we're working with "Flat" Files


Contents of File testf:

Record One
Record Two
Record Three
Last Data Record

File Testf2 has no Data to Start.

Excute the following SQL Statements:

insert into Testf2 Values('*** Header Record ***')

insert into Testf2 select testf from Testf

insert into Testf2  select '*** Trailer Record *** ' ||
Char( count(*) - 1) from Testf2

Contents of File Testf2 to be FTP'd:

*** Header Record ***
Record One
Record Two
Record Three
Last Data Record
*** Trailer Record *** 4


Trailer Record includes Record Count of Data Records Only


Doin't know if that's any easier than what you're doing now.

_________________________________________________________________
Is your PC infected? Get a FREE online computer virus scan from McAfee® Security. http://clinic.mcafee.com/clinic/ibuy/campaign.asp?cid=3963



As an Amazon Associate we earn from qualifying purchases.

This thread ...


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

This mailing list archive is Copyright 1997-2024 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.