Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Loading key sequenced sorted flat file to existing VSAM file

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

New User


Joined: 27 Dec 2005
Posts: 58

PostPosted: Tue Jun 23, 2009 3:21 pm    Post subject: Loading key sequenced sorted flat file to existing VSAM file
Reply with quote

We have a prod VSAM file with customer data for about 100000 customers.its a KSDS file.

We now have a requirement to copy about 10 customer ID's from it
and load them to an existing test VSAM file.

We extracted the data for the 10 customers to a flat file and sorted them on key sequence.

We now want to REPRO this to the test VSAM file.

Please let us know what REPRO option would not overwrite the existing VSAM data in the test file.Also the output should be in correct key sequence.
Back to top
View user's profile Send private message

expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Tue Jun 23, 2009 3:30 pm    Post subject:
Reply with quote

Click HERE to read the IDCAMS manual.
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


Joined: 22 Apr 2006
Posts: 6258
Location: Mumbai, India

PostPosted: Tue Jun 23, 2009 3:34 pm    Post subject:
Reply with quote

Here
Quote:
Please let us know what REPRO option would not overwrite the existing VSAM data in the test file.Also the output should be in correct key sequence.
by overwrite I believe, you meant "append".

My mainframes seesion is not up so can't test and can't tell for sure if this
Quote:
the output should be in correct key sequence
will be taken care (or not) but to append data for those customer IDs for which data might already be there in your "test-VSAM", you may try this:
Code:
REPRO INFILE(FILEIN) OUTFILE(FILEOUT) NOREPLACE
But please take a back-up of your VSAM before any experiment.
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Tue Jun 23, 2009 4:19 pm    Post subject:
Reply with quote

Quote:
by overwrite I believe, you meant "append".

Anuj, You INSERT into a KSDS, you do not append, as the records are always stored in key sequence.

The solution also depends on what the OP means by "overwrite" - does he mean do not overwrite records in the file if they exist, or does he mean do not overwrite the whole file and only be left with the new inserts.

Unfortunately, with it not being psychic day today we can only guess at the requirement.
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 Table(Unicode(Graphic) table) loading... muralikrishnan_new DB2 0 Thu Oct 05, 2017 5:10 pm
No new posts Execute JCL step based on the content... sprikitik JCL & VSAM 2 Tue Oct 03, 2017 10:03 am
This topic is locked: you cannot edit posts or make replies. PS file data should be passed as symb... d_sarlie JCL & VSAM 15 Tue Oct 03, 2017 5:18 am
No new posts VSAM RLS Wait time blayek JCL & VSAM 2 Mon Oct 02, 2017 9:05 pm
No new posts Garbage on output file Hervey Martinez SYNCSORT 4 Wed Sep 27, 2017 12:50 am

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us