Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

how to copy duplicates records from PS to VSAM

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
bhattu

New User


Joined: 05 Jun 2009
Posts: 9
Location: US

PostPosted: Wed Nov 10, 2010 1:32 am    Post subject: how to copy duplicates records from PS to VSAM
Reply with quote

Hi I am trying to copy from PS to VSAM , after copying first 2 reocrds it gives me the following error.

IDC3302I ACTION ERROR ON SUPPORT.TEST.ES46207.TC74951.VSAM
IDC3314I **RECORD OUT OF SEQUENCE - KEY FOLLOWS:
000000 F1F0F0F0 F0F0F0F0 F8F0F2F0 F0F0F0F0 F0F0F0F0 F0F0F4F4 F4F4F4F4 F4F4F4F
000020 F0F1F0F0 F7F1F2F0 F0F0F0F0 F0F0F0F0 F0F0F0C6 40404040 40404040 4040404
000040 40404040 40404040 40404040 40404040 40404040 40404040 40404040 4040404
000060 40404040

IDC3302I ACTION ERROR ON SUPPORT.TEST.ES46207.TC74951.VSAM
IDC3314I **RECORD OUT OF SEQUENCE - KEY FOLLOWS:
000000 F2E84949 2A00240B 0000FFFF FFFFFFF9 2832199B 88BC5523 344CD944 49A3F6F
000020 C2F85FAF FDFFF11F FC77FDFE 61E8C3FE 088F7FFC DC7C8A08 CE371722 4197B08
000040 9999A461 9C3FC9CC 2066E332 241FFF08 3083F4C2 7F841E10 683DBC20 FC26107
000060 B4BD34F8

Here is the JCL which i am using
//JOBCARD
//DELETE EXEC PGM=IDCAMS
//SYSPRINT DD SYSOUT=*
//* DELETE OLD DATASET
DELETE -
SUPPORT.TEST.ES1234.TC1234.VSAM
/*
//DEFINE EXEC PGM=IDCAMS
//SYSPRINT DD SYSOUT=*
//* DEFINE VSAM KSDS DATASET
DEFINE -
CLUSTER -
( -
NAME(SUPPORT.TEST.ES1234.TC1234.VSAM) -
INDEXED -
KEYS(100 0) -
SPEED -
FREESPACE(0 0) -
SHAREOPTIONS(2 3) -
) -
DATA -
( -
NAME(SUPPORT.TEST.ES1234.TC1234.VSAM.DATA)-
CISZ(18432) -
CYLINDERS(10 1) -
RECORDSIZE(101 250101) -
SPANNED -
) -
INDEX -
( -
NAME(SUPPORT.TEST.ES1234.TC1234.VSAM.INDEX) -
CISZ(4096) -
CYLINDERS(5 1) -
)
//JS0010 EXEC PGM=IDCAMS
//SYSOUT DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
//SYSUDUMP DD SYSOUT=*
//ABENDAID DD SYSOUT=*
//TIFFUNLD DD DSN=TEST.IMAGE.FILE,DISP=SHR
//TIFFVSAM DD DSN=SUPPORT.TEST.ES1234.TC1234.VSAM,DISP=SHR
//SYSIN DD *
REPRO INFILE(TIFFUNLD) -
OUTFILE(TIFFVSAM) -

/*

I want to copy the duplicates also to the VSAM file

can you please suggest.
Back to top
View user's profile Send private message

superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4649
Location: Raleigh, NC, USA

PostPosted: Wed Nov 10, 2010 1:38 am    Post subject: Reply to: how to copy duplicates records from PS to VSAM
Reply with quote

Why aren't you using a SORT so that you can assure that all of the keys are in their proper sorted order, and if necessary, deal with duplicates?
Back to top
View user's profile Send private message
bhattu

New User


Joined: 05 Jun 2009
Posts: 9
Location: US

PostPosted: Wed Nov 10, 2010 3:02 am    Post subject:
Reply with quote

hi superk,


Thanks for quick reply, can i use sort to copy to VSAM.

can you send me a sample.
Back to top
View user's profile Send private message
dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Wed Nov 10, 2010 4:09 am    Post subject:
Reply with quote

Hello,

Yes, but you will have to prevent duplicates somehow. . .

There is no need for a sample - there is no special code. . .
Back to top
View user's profile Send private message
bhattu

New User


Joined: 05 Jun 2009
Posts: 9
Location: US

PostPosted: Wed Nov 10, 2010 4:29 am    Post subject:
Reply with quote

Hi dick scherrer,

i got it worked, removed the duplicates.

thanks to all.
Back to top
View user's profile Send private message
dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Wed Nov 10, 2010 8:39 am    Post subject: Reply to: how to copy duplicates records from PS to VSAM
Reply with quote

Good to hear it is working - thank you for letting us know icon_smile.gif

d
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Check if any Detail records and extra... V S Amarendra Reddy SYNCSORT 19 Mon May 08, 2017 8:54 pm
No new posts copy SEQ to PDS and create stats steve-myers JCL & VSAM 7 Thu Apr 27, 2017 1:15 am
No new posts VSAM Space Allocation mrgnndhmk JCL & VSAM 7 Sat Apr 22, 2017 12:42 am
No new posts Copy load modules and alias vasanthz IBM Tools 5 Thu Apr 20, 2017 6:31 am
No new posts Updating a VSAM file with DISP=OLD sheersh JCL & VSAM 8 Tue Mar 14, 2017 6:14 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us