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
 

 

DSUTILTY - Pseudo code look like Assembly but not!!!!

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

New User


Joined: 01 Jun 2009
Posts: 9
Location: India

PostPosted: Tue Jun 02, 2009 3:53 pm    Post subject: DSUTILTY - Pseudo code look like Assembly but not!!!!
Reply with quote

Hi,

I need help to understand the Pseudo code written in the control card of DSUTILTY. I found the similar type of code in WAAPDSUT as well. The step executing this is : -

Code:
//SELECT  EXEC PGM=DSUTILTY,PARM=ABEND                    *********   
//*                                                          *********
//SYSUT1   DD  DSN=input.file,DISP=SHR             
//SYSUT1A  DD  DSN=input.select,DISP=(OLD)                 
//SYSUT2   DD  DSN=output.file,DISP=(,CATLG,CATLG),         
//             UNIT=SYSDA,SPACE=(TRK,(30,90),RLSE)                   
//SYSUT3   DD  DSN=output.err,DISP=(,CATLG,CATLG),       
//             DCB=(RECFM=FB,LRECL=80,BLKSIZE=0) **BLKUP             
//SYSIN    DD  DSN=control.card(logic),DISP=SHR       
//SYSPRINT DD  SYSOUT=0                                               
//*                                                          *********


The logic in control card of SYSIN DD is :-

Code:
         CLC   COUNT1,=X'00000001'                                     
         BE    SYSUT2(RX)            GET DATE REC                       
         CLC   12(8,RX),=C'99999999' GET CONTROL REC                   
         BE    SYSUT2(RX)                                               
         CLC   10(10,RX),0(RY)       MATCH TO INPUT SELECT CARD(S)     
         BE    1                                                       
         BH    2                     GO CHECK IF ANY HITS ON THIS SEL   
         BL    DELETE(RX)            GET NEXT STAT RECORD               
1        BAL   SYSUT2(RX)            WRITE STAT FILE MATCH SELECT CARD 
         MVI   20(RY),C'X'           INDICATE A STAT REC WAS FOUND     
         B     DELETE(RX)              DELETE GO PROCESS NEXT STAT     
2        CLI   20(RY),C'X'           THIS WILL INDICATE A SELECT MADE   
         BE    DELETE(RY)            Y- DELETE AND GO TO THE NEXT I/P   
         MVC   20(41,RY),=C'**E R R O R** NO HIT ON STAT FILE THIS NO' 
         B     SYSUT3(RY)                                               
EOFX     MVC   0(1,RZ),=X'FF'                                           
80       CLC   1(1,RZ),=X'FF'                                           
         BE    EOF                                                     
         CLI   20(RY),C'X'        STAT RECORD FOUND                   
         BNE   81                 NO - GO BUILD ERROR MESSAGE         
         BAL   DELETE(RY)         DROP                               
         B     80                                                     
81       MVC   20(41,RY),=C'**E R R O R** NO HIT ON STAT FILE THIS NO'
         BAL   SYSUT3(RY)                                             
         BAL   DELETE(RY)                                             
         B     80                                                     
EOFY     MVC   1(1,RZ),=X'FF'                                         
90       CLC   0(1,RZ),=X'FF'                                         
         BE    EOF                                                   
         CLC   12(8,RX),=C'99999999' GET CONTROL REC                 
         BE    SYSUT2(RX)                                             
         BAL   DELETE(RX)                                             
         B     90                                                     
         END                                                         



After a test run I found what was done but I need to know exactly how control is flowing through the Pseudo code.

The test result shows following logic:-

input.file has n number of records and input.select has records 10bytes each. The input.select records are those which need to be extracted from the input.file.
The DSUTILTY use the control card to search input.file record by record and if first 10bytes of any record matches with the input.select it writes that record to output.file, and if not found a message get written to output.err file that specific record not found. Except that, two more records got written to output.file; one is date record(at the top of the input.file) and the other one is control record (with 99999... the last record of input.file)

I will be thankful if someone can help me to try run the pseudo code reaching the test result. I need to transform this code to any other to achieve the same thing.

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

Manu Dhawan

New User


Joined: 01 Jun 2009
Posts: 9
Location: India

PostPosted: Wed Jun 03, 2009 6:50 pm    Post subject: Reply to: DSUTILTY - Pseudo code look like Assembly but not!
Reply with quote

Any documentation over WAAPDSUT or DSUTILTY will be helpful too. I checked in our store but strangly couldn't find anything useful. Awaiting help.

Thanks,
Manu
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10274
Location: italy

PostPosted: Wed Jun 03, 2009 7:07 pm    Post subject: Reply to: DSUTILTY - Pseudo code look like Assembly but not!
Reply with quote

do not hold too many hopes,
the question is too much site specific to expect an answer,

the consequences of using undocumented tools and interfaces should have been clear
to Your organization from the beginning

the best thing to do is to look at the application flow to understand what is going on
and rewrite the logic using sort ( dfsort or syncsort ) tools, very good at file matching
or a cobol program

Quote:
Awaiting help.

be careful not to get a S522 abend ( wait time limit exceeded )
Back to top
View user's profile Send private message
Manu Dhawan

New User


Joined: 01 Jun 2009
Posts: 9
Location: India

PostPosted: Thu Jun 04, 2009 12:20 pm    Post subject: Re: Reply to: DSUTILTY - Pseudo code look like Assembly but
Reply with quote

Quote:

be careful not to get a S522 abend ( wait time limit exceeded )


HA HA...lol

Recently got the documentation on WAAPDSUT/DSUTILTY.

Will be converting the logic to DLY280.
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


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

PostPosted: Thu Jun 04, 2009 3:16 pm    Post subject:
Reply with quote

Hi,

May be searching under ISRDDN about this utility can give you some documentation in comments -- but beware, comments may lie.

Quote:
be careful not to get a S522 abend
She seems to be lucky, didn't get S222... 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 -> 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 UNIT=AFF for Easytrieve code gandikk JCL & VSAM 7 Wed Jul 12, 2017 11:42 pm
No new posts DB2 Program abending without giving a... rahulgarg14 DB2 7 Mon May 29, 2017 8:10 pm
No new posts Job failing with USER = 4093 REASON C... Pradeepa S ABENDS & Debugging 1 Wed May 17, 2017 3:35 pm
No new posts COBOL Code Parsers and Lineage Establ... balimanja COBOL Programming 2 Tue May 02, 2017 3:30 am
No new posts Cobol upgrade - source code missing f... gthmrj IBM Tools 1 Wed Apr 26, 2017 6:04 pm


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