I'm trying to write a small program to run my backup job via BRMS... and I would like to check the different errors and reply automatically to few of them.
Ok, I can monitor the error messages through MONMSG but how can I reply to them ?
I know that I have to use SNDRPY but how can I have the Message Key???
Here is a short part of one of my tries:
MONMSG MSGID(BRM1033) EXEC(GOTO CMDLBL(RESTART))
MONMSG MSGID(BRM0000) EXEC(GOTO CMDLBL(ERROR))
RCVMSG MSGTYPE(*LAST) KEYVAR(&MSGKY)
SNDRPY MSGKEY(&MSGKY) MSGQ(QSYSOPR) RPY('C')
When running this code, here is the error that I have: CPF2410: Message key not found in message queue QSYSOPR.
Perhaps, I need to specify in the RCVMSG the MSGQ: MSGQ(QSYSOPR) ?
If yes... OK, it'll work... but what about if the configured BRMS send all its messages to another MSGQ ?
I've an other question... How can we make sure that the message received by the command RCVMSG MSGTYPE(*LAST) will be only the message BRM1033.
Thanks for your help,
November 2, 2006 3:00 AM
December 25, 2009 2:20 AM