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
 

 

VB file sorting

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL
View previous topic :: :: View next topic  
Author Message
V S Amarendra Reddy

Active User


Joined: 13 Sep 2006
Posts: 189
Location: INDIA

PostPosted: Fri Feb 26, 2016 8:29 pm    Post subject: VB file sorting
Reply with quote

Input file:VBA, record length=240
Code:

 DSNT490I SAMPLE DATA UNLOAD PROGRAM                                           
 DSNT505I DSNTIAUL OPTIONS USED: SQL                                           
 DSNT503I UNLOAD DATA SET SYSPUNCH RECORD LENGTH SET TO    80                   
 DSNT504I UNLOAD DATA SET SYSPUNCH BLOCK SIZE SET TO 27920                     
 DSNT506I INPUT STATEMENT WAS NOT A FULL SELECT ON A SINGLE TABLE. LOAD STATEMEN
 DSNT503I UNLOAD DATA SET SYSREC00 REC456 LENGTH SET TO   269                   
 DSNT504I UNLOAD DATA SET SYSREC00 BLOCK SIZE SET TO 27976                     
 DSNT495I SUCCESSFUL UNLOAD            1 ROWS OF TABLE TBLNAME                 
 DSNT506I INPUT STATEMENT WAS NOT A FULL SELECT ON A SINGLE TABLE. LOAD STATEMEN
 DSNT503I UNLOAD DATA SET SYSREC01 REC786 LENGTH SET TO   526                   
 DSNT504I UNLOAD DATA SET SYSREC01 BLOCK SIZE SET TO 27878                     
 DSNT495I SUCCESSFUL UNLOAD            5 ROWS OF TABLE TBLNAME                 


Sort control card I am using is

Code:

OPTION COPY,VLSHRT                                   
INCLUDE COND=(38,6,SS,EQ,C'00 REC,01 REC')           
SORT FIELDS=(44,3,ZD,D)                             
OUTFIL BUILD=(34,7,64,4,UFF,EDIT=(TTTT),80:X),CONVERT


I am trying to sort the records with the strings REC456, REC786 that are in byte 44(that includes RDW).

Current Output
Code:

REC00 0269
REC01 0526


Expected Output
Code:

REC01 0526
REC00 0269


What is the mistake in the control card?

Regards
Amar
Back to top
View user's profile Send private message

RahulG31

Active User


Joined: 20 Dec 2014
Posts: 343
Location: USA

PostPosted: Fri Feb 26, 2016 10:07 pm    Post subject: Reply to: VB file sorting
Reply with quote

Remove
Code:
OPTION COPY

Quote:
The sort statement is ignored because the COPY option has been specified.


.
Back to top
View user's profile Send private message
V S Amarendra Reddy

Active User


Joined: 13 Sep 2006
Posts: 189
Location: INDIA

PostPosted: Fri Feb 26, 2016 11:09 pm    Post subject:
Reply with quote

Sometimes the answer is right in front of the face and can't notice it. icon_biggrin.gif I was doing lot of permutations and combinations and didn't notice this.

Thank you for highlighting and it worked. icon_smile.gif
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 -> DFSORT/ICETOOL All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Changing of LRECL of a file abdulrafi DFSORT/ICETOOL 1 Fri Mar 24, 2017 3:25 pm
No new posts splitting a file abdulrafi DFSORT/ICETOOL 3 Fri Mar 24, 2017 11:51 am
No new posts Receive a file using PCOMM macro Harald.v.K IBM Tools 0 Thu Mar 23, 2017 6:50 pm
No new posts Export flat file data into excel sheet murali.andaluri DFSORT/ICETOOL 2 Mon Mar 20, 2017 5:39 pm
No new posts Formatting VB File Learncoholic DFSORT/ICETOOL 3 Mon Mar 20, 2017 12:29 pm


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