Add header and trailer to four files



IBM's flagship sort product DFSORT for sorting, merging, copying, data manipulation and reporting. Includes ICETOOL and ICEGENER

Add header and trailer to four files

Postby cbhargavi » Mon Nov 26, 2012 5:58 pm

Hi every one...my requirement is i have four input files.I want to add header and trailer to all files at a time by using sort card.
can we have that possiblity of getting more output files using sort card.
input files:four files.
1 .contains records A
2.Contains records B
3.Contains records C
4.Contains records D

out put should be
1.H
A
T in this format for every file..

I know the header and trailer sort cards.the thing is using same sort card i want to add header and trailer for each input file and get the output files respectively using header ,trailer sort card.
Do we have that possiblilty.Can anybody help me
cbhargavi
 
Posts: 20
Joined: Mon Oct 15, 2012 5:43 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Add header and trailer to four files

Postby BillyBoyo » Mon Nov 26, 2012 6:15 pm

Why do you want to do four at once? What is wrong with a step to do one, and run the step four times?
BillyBoyo
Global moderator
 
Posts: 3804
Joined: Tue Jan 25, 2011 12:02 am
Has thanked: 22 times
Been thanked: 265 times

Re: Add header and trailer to four files

Postby dick scherrer » Mon Nov 26, 2012 11:03 pm

Hello and welcome to the forum,

And Please - no - note this is Not the requirement. The requirement may be to add headers and trailers, but i would ask why the process(es) that create the files do not do it correctly/completely with no need to pass all of the data again to add h/t records?
Hope this helps,
d.sch.
User avatar
dick scherrer
Global moderator
 
Posts: 6268
Joined: Sat Jun 09, 2007 8:58 am
Has thanked: 3 times
Been thanked: 93 times

Re: Add header and trailer to four files

Postby skolusu » Mon Nov 26, 2012 11:38 pm

cbhargavi wrote:Hi every one...my requirement is i have four input files.I want to add header and trailer to all files at a time by using sort card.
can we have that possiblity of getting more output files using sort card.
input files:four files.
1 .contains records A
2.Contains records B
3.Contains records C
4.Contains records D

out put should be
1.H
A
T in this format for every file..

I know the header and trailer sort cards.the thing is using same sort card i want to add header and trailer for each input file and get the output files respectively using header ,trailer sort card.
Do we have that possiblilty.Can anybody help me


cbhargavi,

1. What is the LRECL and RECFM of the files involved?
2. Is there any indicator in the records which can be used to identify as to which file the record begins?
Kolusu - DFSORT Development Team (IBM)
DFSORT is on the Web at:
www.ibm.com/storage/dfsort
skolusu
 
Posts: 586
Joined: Wed Apr 02, 2008 10:38 pm
Has thanked: 0 time
Been thanked: 39 times

Re: Add header and trailer to four files

Postby cbhargavi » Tue Nov 27, 2012 12:33 pm

Thanks for your quick response.This is one of the part in a code.I can do it for each file in each step.Steps will get increased.As the task is same that why i want to do in a single step.
All the input files has different record lengths.
cbhargavi
 
Posts: 20
Joined: Mon Oct 15, 2012 5:43 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Add header and trailer to four files

Postby BillyBoyo » Tue Nov 27, 2012 1:01 pm

Why don't you answer Kolusu's questions?
BillyBoyo
Global moderator
 
Posts: 3804
Joined: Tue Jan 25, 2011 12:02 am
Has thanked: 22 times
Been thanked: 265 times

Re: Add header and trailer to four files

Postby cbhargavi » Tue Nov 27, 2012 4:46 pm

The input files has different record lengths and record format=FB
cbhargavi
 
Posts: 20
Joined: Mon Oct 15, 2012 5:43 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Add header and trailer to four files

Postby BillyBoyo » Tue Nov 27, 2012 5:09 pm

Since you can't concatenate FBs with different LRECLs in DFSORT this would be a problem.

If you put everything in a PROC and supply input/output to the PROC, I think one-at-a-time would be the way forward.
BillyBoyo
Global moderator
 
Posts: 3804
Joined: Tue Jan 25, 2011 12:02 am
Has thanked: 22 times
Been thanked: 265 times

Re: Add header and trailer to four files

Postby cbhargavi » Tue Nov 27, 2012 5:32 pm

yes that will be fine..I want to know the possibility..thanks you
cbhargavi
 
Posts: 20
Joined: Mon Oct 15, 2012 5:43 pm
Has thanked: 0 time
Been thanked: 0 time

Space constraints

Postby cbhargavi » Wed Nov 28, 2012 1:56 pm

hi everyone,
This is my file containg the records,
HXY111128201201:52:44
D1234567
D1122333        abcdefgi
TXY000000000000002

This file rlecl=24,FB
In mainframes all the gaps are looking spaces..its fine.
But when i copied this to notepad,the page end is showing after D1234567 this data not at page end means at 24 position.

Can any one help me..What i can do..wher eis the mistake.
Do i need to use any sort card for this case
cbhargavi
 
Posts: 20
Joined: Mon Oct 15, 2012 5:43 pm
Has thanked: 0 time
Been thanked: 0 time

Next

Return to DFSORT/ICETOOL/ICEGENER

 


  • Related topics
    Replies
    Views
    Last post