MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Conditional repro.

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Utilities
View previous topic :: View next topic  
Author Message
krk123
Beginner


Joined: 03 Jun 2003
Posts: 58
Topics: 19

PostPosted: Fri Nov 07, 2003 3:31 pm    Post subject: Conditional repro. Reply with quote

Hi,
I am trying copy records from a very big flat file to a VSAM file. I am using repro to copy. Is there anyway we can specify a condition while copying i.e I am looking for something like

SORT FIelds=copy
include cond=(10,5,ch,eq,c'xxxxx).

Is this possible to do with repro.

regards,
KRK123
Back to top
View user's profile Send private message
Cogito-Ergo-Sum
Advanced


Joined: 15 Dec 2002
Posts: 637
Topics: 43
Location: Bengaluru, INDIA

PostPosted: Fri Nov 07, 2003 4:06 pm    Post subject: Reply with quote

Krk,
Why would you not want to use SORT??

Anyway, REPRO does have conditional copying capability. But, it is limited to ranges. That is, you can copy records between FROMKEY and TOKEY or, between FROMADDRESS and TOADDRESS and, between FROMNUMBER to TONUMBER. Niether of these will help you.

So, the answer is NO.
_________________
ALL opinions are welcome.

Debugging tip:
When you have eliminated all which is impossible, then whatever remains, however improbable, must be the truth.
-- Sherlock Holmes.
Back to top
View user's profile Send private message
Frank Yaeger
Sort Forum Moderator
Sort Forum Moderator


Joined: 02 Dec 2002
Posts: 1618
Topics: 31
Location: San Jose

PostPosted: Fri Nov 07, 2003 4:28 pm    Post subject: Reply with quote

KRK123,

You can use DFSORT to copy the large flat file to a VSAM file. Just specify SORTIN as the flat file and SORTOUT as the VSAM file. That will allow you to use the DFSORT INCLUDE statement you want.
_________________
Frank Yaeger - DFSORT Development Team (IBM)
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
DFSORT is on the Web at:
www.ibm.com/storage/dfsort
Back to top
View user's profile Send private message Send e-mail Visit poster's website
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12378
Topics: 75
Location: San Jose

PostPosted: Fri Nov 07, 2003 4:39 pm    Post subject: Reply with quote

Cogito,

you are partially correct. If the input file is KSDS or ISAM(no longer supported) then you can use repro with include cond.

The technique is to code the same key for both the FROMKEY & TOKEY

for ex:
Code:

 REPRO IFILE(IN) OFILE(OUT) FROMKEY('AAAAAA') TOKEY('AAAAA')


In this case you can just copy the key aaaaa.

This will not work for KRK as his input file is a flat file which means DSORG is PS which is accessed via QSAM mode.

Krk use sort to copy it to vsam as sort products are highly optomized for I/O. Just make sure that you have defined the vsam file as REUSE.

Hope this helps...

cheers

kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Cogito-Ergo-Sum
Advanced


Joined: 15 Dec 2002
Posts: 637
Topics: 43
Location: Bengaluru, INDIA

PostPosted: Fri Nov 07, 2003 4:52 pm    Post subject: Reply with quote

Kolusu,
I am aware of that technique. As his input is PS, I did not post it.

I should have posted it to maintain some "generality".
_________________
ALL opinions are welcome.

Debugging tip:
When you have eliminated all which is impossible, then whatever remains, however improbable, must be the truth.
-- Sherlock Holmes.
Back to top
View user's profile Send private message
krk123
Beginner


Joined: 03 Jun 2003
Posts: 58
Topics: 19

PostPosted: Sat Nov 08, 2003 6:44 pm    Post subject: Reply with quote

Cogito, Kolusu & Frank thanks a lot for your help and your time. I will use DFSORT.

Regards,
krk123
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Utilities All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group