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 

Selective read-write from a VB file

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


Joined: 31 Mar 2003
Posts: 29
Topics: 13

PostPosted: Mon Jun 02, 2008 2:54 pm    Post subject: Selective read-write from a VB file Reply with quote

Hello,
I need a JCL to compare 2 VB files of LRECL 730.
In that JCL I need to see if the record type ( on pos 17th) is a "OO" and when it is OO, then it should read positions 1 thru 12 and 257 thru 265 and write it on to a seperate file.

PS: Postion 257 thru 265 on the 'OO' type record is hex coded. It would be great if this is converted too.

Appreciate your help..


thanks!
sk
_________________
Thanks!,
Santosh Kulkarni
Back to top
View user's profile Send private message
kolusu
Site Admin
Site Admin


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

PostPosted: Mon Jun 02, 2008 3:05 pm    Post subject: Reply with quote

eskaysem,

You are asking 2 separate issues. First you say you want to compare and then you say you want to extract the contents . if your intention is to copy the contents when the record is OO to a FB dataset then use the following control cards

we add 4 to the actual pos as VB have the RDW.
Code:

//SYSIN    DD *                     
  SORT FIELDS=COPY                 
  INCLUDE COND=(21,2,CH,EQ,C'OO')   
  OUTFIL VTOF,BUILD=(5,12,261,9)   
/*                                 


Hope this helps...

Cheers
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
eskaysem
Beginner


Joined: 31 Mar 2003
Posts: 29
Topics: 13

PostPosted: Mon Jun 02, 2008 4:31 pm    Post subject: Reply with quote

Thanks for your help Kolusu.
When I used syncsort with the control card you specified, I'm getting an error saying "Build is unidentified". I dont think we do have DFSort utility here.

Regards,
Sk
_________________
Thanks!,
Santosh Kulkarni
Back to top
View user's profile Send private message
amargulies
Beginner


Joined: 10 Jan 2007
Posts: 123
Topics: 0

PostPosted: Tue Jun 03, 2008 10:56 am    Post subject: Reply with quote

eskaysem wrote:
I'm getting an error saying "Build is unidentified".

If you are running SyncSort for z/OS 1.2.1.0 or later, then the control statements specified should work fine.

However, if you are on an earlier release of SyncSort, then you can simply change BUILD to OUTREC and the job should run.

If you are still encountering a problem, please feel free to contact me offline at alissa.margulies@syncsort.com with the complete job listing and I would be happy to assist you further.
_________________
Alissa Margulies
SyncSort Mainframe Product Services
201-930-8260
zos_tech@syncsort.com
Back to top
View user's profile Send private message Send e-mail
eskaysem
Beginner


Joined: 31 Mar 2003
Posts: 29
Topics: 13

PostPosted: Tue Jun 03, 2008 2:12 pm    Post subject: Reply with quote

Thank you Alissa and Kolusu.
I was able to copy the contents using fileaid.

Another issue I'm facing now is some part of the data is EBCDIC and is there anyway that when I copy over(probably could be nother step?) to the destined dataset, could it be in the printable format?

The EBCDIC data starts on postion 18 thru 22 and 24 thru 28.

Thanks a lot!!
Santosh
_________________
Thanks!,
Santosh Kulkarni
Back to top
View user's profile Send private message
Nic Clouston
Advanced


Joined: 01 Feb 2007
Posts: 1075
Topics: 7
Location: At Home

PostPosted: Tue Jun 03, 2008 2:58 pm    Post subject: Reply with quote

If it is on MVS then probably the entire file is in EBCDIC. Do you mean some of the decimal data is in PACKED DECIMAL format and you would like to convert it to ZONED DECIMAL i.e. eye-readable? IF so, tthis is definitely possible with the sort facilities - you can read the manual or search this forum for examples.
_________________
Utility and Program control cards are NOT, repeat NOT, JCL.
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