如何在HCXX

时间:2015-10-22 15:56:29

标签: rexx

我正在尝试将LINE.I的值复制到变量THIS_IS_A_COMMENT2,以便我可以将其用于我的JCL。

正确生成并执行JCL,但完全忽略了行QUEUE "//* THIS IS A COMMENT2 : " THIS_IS_A_COMMENT2

SAY "VALUE OF LINE.I : " LINE.I工作正常,我无法将LINE.I的值复制到一个简单变量。

THIS_IS_A_COMMENT  = "HELLO"
THIS_IS_A_COMMENT2 = ""

DO I = 1 TO LINE.0
    SAY "VALUE OF LINE.I : " LINE.I

    THIS_IS_A_COMMENT2 = LINE.I

    QUEUE "//USERIDK JOB 0000,'HELLO',"
    QUEUE "//            CLASS=T,"
    QUEUE "//            MSGCLASS=X,"
    QUEUE "//            MSGLEVEL=(1,1),"
    QUEUE "//            USER=USERID,"
    QUEUE "//            PASSWORD="
    QUEUE "//* THIS IS A COMMENT  : " THIS_IS_A_COMMENT
    QUEUE "//* THIS IS A COMMENT2 : " THIS_IS_A_COMMENT2
    QUEUE "//STEP1 EXEC PGM=IEFBR14"
    QUEUE "//DD1 DD DUMMY"
    QUEUE "/*"
    QUEUE "$$"
    O = OUTTRAP("OUTPUT.",,"CONCAT")
    "SUBMIT * END($$)"
    O = OUTTRAP(OFF)
END

我使用以下jcl提交我的rexx代码:

//JCLSAYHI JOB 00000,'SAY HI',
//             CLASS=T,
//             MSGCLASS=X,
//             MSGLEVEL=(1,1),
// USER=MYUSER,PASSWORD=
/*JOBPARM R=H101,T=999,L=9999,S=ANY
//*----------------------------------------------
//STEPREXX EXEC PGM=IKJEFT01,PARM='SAYHI3'
//SYSEXEC  DD DISP=SHR,DSN=MYUSER.REXX
//SYSTSPRT DD SYSOUT=*
//SYSTSIN  DD DUMMY
//MYDATA   DD DISP=SHR,DSN=MYUSER.REXX.DATASET

SYSEXEC执行上面的代码,MYUSER.REXX.DATASET数据集包含:

********************************* Top of Data ******
HELLO1
HELLO2
HELLO3
HELLO4
HELLO5
******************************** Bottom of Data ****

跟踪结果

发现问题(REXX在THIS IS A COMMENT2行的末尾不添加双引号,因此在生成的JCL中忽略该行)。只是不确定如何解决这个问题:

27 *-*  QUEUE "//* THIS IS A COMMENT  : " THIS_IS_A_COMMENT
    >>> "//* THIS IS A COMMENT  :  HELLO"
28 *-*  QUEUE "//* THIS IS A COMMENT2 : " THIS_IS_A_COMMENT2 ""
    >>> "//* THIS IS A COMMENT2 :  HELLO1     <--- DOUBLE QUOTE MISSING AT THE END HERE

0 个答案:

没有答案