Repro from sequential to VSAM file handeling the duplicate



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

Repro from sequential to VSAM file handeling the duplicate

Postby ajuatsgp » Wed Aug 25, 2010 7:41 pm

I have a sequential file with data as:

0302082010000000000000015
0502082010000000000000005
0702082010000000000000017
0802082010000000000000012
2002082010000000000000023

I want to Repro it to a VSAM file which has data:


0112122010000000000000008
0212122010000000000000009
0412122010000000000000009
0512122010000000000000008
0702082010000000000000017
1012122010000000000000015
1212102010000000000000001
3112122010000000000000001

The digits in RED are key of the VSAM file.
But the record in BOLD is a duplicate record.

My requirement is such that after doing the Repro the record in BOLD should be 0702082010000000000000032. My requirement is such that the last 15 digits which is counts of those records should be added.
ajuatsgp
 
Posts: 82
Joined: Thu May 20, 2010 6:50 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Repro from sequential to VSAM file handeling the duplicate

Postby MrSpock » Wed Aug 25, 2010 8:49 pm

REPRO is not going to add two fields and sum them. Why aren't you looking for a solution using your SORT product?
User avatar
MrSpock
Global moderator
 
Posts: 807
Joined: Wed Jun 06, 2007 9:37 pm
Location: Raleigh NC USA
Has thanked: 0 time
Been thanked: 4 times

Re: Repro from sequential to VSAM file handeling the duplicate

Postby ajuatsgp » Wed Aug 25, 2010 10:09 pm

Can u please help me...I mean how can I get the desired output.
Let me tell again input file is a sequential file and output is a VSAM file.
I can use any number of intermediate file if required
ajuatsgp
 
Posts: 82
Joined: Thu May 20, 2010 6:50 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Repro from sequential to VSAM file handeling the duplicate

Postby dick scherrer » Thu Aug 26, 2010 12:07 am

Hello,

Which sort product is used on your system?

The informational output from a sort shows the product . . .
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: Repro from sequential to VSAM file handeling the duplicate

Postby ajuatsgp » Thu Aug 26, 2010 5:24 am

Hi,
DFSORT is used?
Still I am confused how to get the desired output.As my output file is a VSAM file.
Please help thanks.
ajuatsgp
 
Posts: 82
Joined: Thu May 20, 2010 6:50 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Repro from sequential to VSAM file handeling the duplicate

Postby Frank Yaeger » Thu Aug 26, 2010 5:41 am

DFSORT can use a VSAM file as output. Why do you think it can't?
Frank Yaeger - DFSORT Development Team (IBM) - yaeger@us.ibm.com
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
=> DFSORT/MVS is on the Web at http://www.ibm.com/storage/dfsort
User avatar
Frank Yaeger
Global moderator
 
Posts: 1079
Joined: Sat Jun 09, 2007 8:44 pm
Has thanked: 0 time
Been thanked: 15 times

Re: Repro from sequential to VSAM file handeling the duplicate

Postby ajuatsgp » Thu Aug 26, 2010 7:33 am

Hi,
If there is no matching key it should simply add a new record to the VSAM file.
In case of duplicate keys It should add the COUNT(i.e, thes last 15 digits) of the input sequential file to that of the output VSAM file and the record in the VSAM file should be updated with new count.
Input seq file:
Organization . . . : PS
Record format . . . : FB
Record length . . . : 25

Output VSAM file:
KSDS key length: 10
KSDS key location: 0
Average record size: 25
Maximum record size: 25
ajuatsgp
 
Posts: 82
Joined: Thu May 20, 2010 6:50 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Repro from sequential to VSAM file handeling the duplicate

Postby dick scherrer » Thu Aug 26, 2010 7:47 am

Hello,

Can you tell me how can I get my desired output?
You need to post the exact specifics of your requirement.

It will be better if you add at least one more duplicate and show the complete content of the output vsam file after your process has run. For example - what should happen with input sequential data that does NOT have a matching key on the input vsam file? Is this to be bypassed or added to the output vsam file?

If there are any other "rules" you need to post these as well. Mention the dsorg and lrecl of the files.
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: Repro from sequential to VSAM file handeling the duplicate

Postby ajuatsgp » Thu Aug 26, 2010 8:08 am

Hi,
If there is no matching key it should simply add a new record to the VSAM file.
In case of duplicate keys It should add the COUNT(i.e, thes last 15 digits) of the input sequential file to that of the output VSAM file and the record in the VSAM file should be updated with new count.
Input seq file:
Organization . . . : PS
Record format . . . : FB
Record length . . . : 25

Output VSAM file:
KSDS key length: 10
KSDS key location: 0
Average record size: 25
Maximum record size: 25


Please let me know if you need any more info...
ajuatsgp
 
Posts: 82
Joined: Thu May 20, 2010 6:50 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Repro from sequential to VSAM file handeling the duplicate

Postby ajuatsgp » Thu Aug 26, 2010 11:10 am

Hi Dick,

Any solution for my problem???
ajuatsgp
 
Posts: 82
Joined: Thu May 20, 2010 6:50 pm
Has thanked: 0 time
Been thanked: 0 time

Next

Return to DFSORT/ICETOOL/ICEGENER

 


  • Related topics
    Replies
    Views
    Last post