Hi Joe,

As I understand your problem, you have progressed beyond the S0C4 when
invoking IDCAMS dynamically, but are now faced with the situation that
SYSPRINT does not flow elegantly as you would expect.

If this is the case it may be nothing to do with the calling rogram, but a
problem with the JCL. I spent 30 minutes producing the following code and
JCL to test dynamic invocation of IDCAMS, and SYSPRINT appeared as I had
anticipated it would, i.e. in the same format as when viewed via SDSF,
albeit in a data set now.

Assembler Code - (Not elegant but it was under 30 minutes remember)

         PRINT NOGEN                                                   
KMSASM   CSECT                                                         
         USING *,R15                   INITIAL BASE REGISTER           
BEGIN    B     START                                                   
         DC    AL1(8),CL8'KMSASM'      PROGRAM NAME FOR DEBUGGING      
*----P-O-S-I-T-I-O-N-A-L-L-Y----D-E-P-E-N-D-A-N-T----C-O-D-E----------*
SAVEAREA DS    0F                      MY SAVE AREA                   *
         DC    AL4(*-*)                                               *
PRESAVE  DC    AL4(*-*)                ADDR OF PREVIOUS SAVE AREA     *
NEXTSAVE DC    AL4(*-*)                ADDR OF NEXT SAVE AREA         *
SREG14   DC    AL4(*-*)                GENERAL                        *
SREG15   DC    AL4(*-*)                       PURPOSE                 *
SREG0    DC    13AL4(*-*)                            REGISTER SAVE    *
SAVEEND  DS    0H                      END OF MY SAVE AREA            *
*---------------------------------------------------------------------*
         SPACE 1                                                       
         DROP  R15                     LOOSE INITAL BASE               
START    BAKR  14,0                    STACK REGISTERS ETC             
         LR    R12,R15                 SET BASE ADDRESS, AND          
         USING BEGIN,R12                   TELL THE COMPILER.         
         ST    R13,SAVEAREA+4          NOW SAVE REGISTER 13 CONTENTS  
         LA    R13,SAVEAREA            R13 = MY SAVE AREA ADDRESS     
         OPEN  (SYSIN,OUTPUT)          OPEN THE FILES.                
         PUT   SYSIN,IDCAMSCC          WRITE MY AMS CONTROL CARD      
         CLOSE (SYSIN)                 CLOSE SYSIN READY FOR IDCAMS   
         LINK  EP=IDCAMS,PARAM=(AMSOPT),VL=1                          
         PR                            RETURN WHENCE I CAME           
         EJECT                                                        
         LTORG                                                        
AMSOPT   DC    H'0'                                                   
SYSIN    DCB   MACRF=PM,DDNAME=SYSIN,DSORG=PS,LRECL=80                
IDCAMSCC DC    CL80' LISTC LVL(ASMMST) '                              
         COPY  REGS                                                   
         END                                                          

Invoking JCL

//ADCDMSTJ JOB  CLASS=A,MSGCLASS=X,NOTIFY=&SYSUID                
//S0010    EXEC PGM=KMSAMS                                       
//STEPLIB  DD   DSN=USER.LINKLIB,DISP=SHR                        
//SYSPRINT DD   DSN=&SYSUID..IDCAMS.SYSPRINT,LRECL=121,RECFM=FBA,
//             UNIT=SYSDA,BLKSIZE=1210,SPACE=(TRK,(1,1)),        
//             DISP=(,CATLG)                                     
//SYSIN    DD   UNIT=SYSDA,SPACE=(TRK,1),BLKSIZE=80,RECFM=F      

Kind Regards - Terry
 
Director
KMS-IT Limited
228 Abbeydale Road South
Dore
Sheffield
S17 3LA
UK
 
Reg : 3767263
 
Outgoing e-mails have been scanned, but it is the recipients responsibility
to ensure their anti-virus software is up to date.
 
 


----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html

Reply via email to