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
 
Sort include cond

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

New User


Joined: 29 Dec 2008
Posts: 37
Location: india

PostPosted: Thu Mar 25, 2010 10:41 pm    Post subject: Sort include cond
Reply with quote

Hi,

This is the job step :

Code:
//S02 EXEC PGM=SORT                                             
//SYSOUT   DD  SYSOUT=*                                         
//SORTMSG  DD  SYSOUT=*                                         
//SORTIN DD DSN=ABC.DEF.123,DISP=SHR           
//SORTOUT DD DSN=ABC.DEF.234,                 
//           DISP=SHR                                           
//SYSIN DD *                                                   
  SORT FIELDS=COPY                                             
  INCLUDE COND=(6,07,CH,EQ,C'NONVSAM')                         
  OUTFIL OUTREC=(C' DELETE ',12:21,36),CONVERT                 
//*                                                             

Here include cond means that starting location is 6 and length of 7 should match 'NONVSAM' string.

When I am opening PS file(ABC.DEF.123) in view/Edit mode i am seeing this ..

Code:
Command ===>                                                  Scroll ===> CSR 
=COLS> ----+----1----+----2----+----3----+----4----+----5----+----6----+----7--
000006 0NONVSAM ------- XXX.123.LONG.GDG100.G0001V00             
000007       IN-CAT --- UCAT.TSO                                               
000008 0NONVSAM ------- XXX.123.LONG.GDG100.G0002V00             
000009       IN-CAT --- UCAT.TSO   

Isn't the starting position for 'NONVSAM' here is column 2 ? But the INCLUDE COND=(6,07,CH,EQ,C'NONVSAM') working perfectly fine. Am i reading the input column number incorrectly?

Please correct me.

Thanks,
Back to top
View user's profile Send private message

CICS Guy

Senior Member


Joined: 18 Jul 2007
Posts: 2150
Location: At my coffee table

PostPosted: Thu Mar 25, 2010 10:56 pm    Post subject:
Reply with quote

Quote:
Isn't the starting position for 'NONVSAM' here is column 2 ? But the INCLUDE COND=(6,07,CH,EQ,C'NONVSAM') working perfectly fine. Am i reading the input column number incorrectly?
If the PS file were actually VB rather than FB, the 6 for 7 makes sense.....
Back to top
View user's profile Send private message
kapil dev arora

New User


Joined: 29 Dec 2008
Posts: 37
Location: india

PostPosted: Thu Mar 25, 2010 11:00 pm    Post subject:
Reply with quote

Here are the PS file properties. Can you please tell me how to read column number from input files. How '6 for 7 makes sense'. What will be the first column then ?

General Data
Management class . . : MCTEST
Storage class . . . : SCTEST
Volume serial . . . : TST007 +
Device type . . . . : 3390
Data class . . . . . : DCEXTDEF
Organization . . . : PS
Record format . . . : VBA
Record length . . . : 240
Block size . . . . : 3120
1st extent blocks . : 180
Secondary blocks . : 500
Data set name type : EXTENDED
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Moderator


Joined: 15 Feb 2005
Posts: 7130
Location: San Jose, CA

PostPosted: Thu Mar 25, 2010 11:25 pm    Post subject:
Reply with quote

A VBA file has an RDW (in positions 1-4), a carriage control character (in position 5) and then the data (starting in position 6).

View does not show you the RDW - it starts with the carriage control character (e.g. '0').

As far as DFSORT is concerned, 'NONVSAM' is the first data byte which starts in position 6.
Back to top
View user's profile Send private message
kapil dev arora

New User


Joined: 29 Dec 2008
Posts: 37
Location: india

PostPosted: Fri Mar 26, 2010 12:47 am    Post subject: Reply to: Sort include cond
Reply with quote

That was really good information. Thanks :-)
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 sort records based on length exceeds ... maxsubrat DFSORT/ICETOOL 7 Wed Oct 04, 2017 4:48 pm
No new posts JOINKEYS Paired and Unpaired Sort MFwhiz DFSORT/ICETOOL 4 Fri Sep 29, 2017 1:48 am
No new posts Difference in SORT & ICETOOL Mohan Kothakota DFSORT/ICETOOL 5 Fri Sep 22, 2017 4:56 pm
No new posts More than 1 Include criteria for sing... Roy Ware SYNCSORT 6 Wed Sep 13, 2017 11:45 pm
No new posts OC4 in SORT Mohan Kothakota DFSORT/ICETOOL 2 Tue Sep 12, 2017 6:30 pm

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