Deleting SAVED journal receivers

175 pts.
Tags:
AS/400
AS/400 journaling
CL Program
I want to delete journal receivers in a library that have the the status of SAVED. Can anyone offer some CL code to do this in a program? Each receiver begins with AMQA and followed by 6 numerics. I guess I would write out to an outfile then read the outfile to delete the receivers.

Software/Hardware used:
V6R1
ASKED: April 29, 2013  7:11 PM
UPDATED: April 30, 2013  11:57 AM

Answer Wiki

Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Discuss This Question: 1  Reply

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
  • TomLiotta
    Basic code in a CL program could center around something like this:
    DLTJRNRCV  JRNRCV( MyLib/AMQA* )
    MONMSG     MSGID( CPF2100 )             /* Skips unsaved rcvrs */
    MONMSG     MSGID( CPF7000 ) EXEC( DO )  /* Specific errors...  */
    ENDDO
    MONMSG     MSGID( CPF9800 ) EXEC( DO )  /* General errors...   */
    ENDDO
    The MONMSG for CPF2100 will simply ignore the generic group of *ESCAPE messages for CPF21hh where 'hh' is any pair of hex digits. The likely message will be CPF2117 that comes because one or more receivers will be attached or otherwise not yet saved.
    .
    The MONMSG CPF7000 is for a generic set of CPF70hh *ESCAPE messages that might happen for journal error conditions. You can put code into the DO-group that sends messages or does whatever you think should be done in the situation. If you put nothing in the DO-group, the errors will effectively be ignored as if you never coded the EXEC() parameter at all. If you don't code the MONMSG, the *ESCAPE message will cause any program-level MONMSG to be activated or will throw an error for the job.
    .
    The MONMSG CPF9800 will catch general object CPF98hh *ESCAPE messages that aren't specific to journals. This works the same as the one for CPF7000.
    .
    In general, that code should simply delete all saved receivers and ignore others.
    .
    Tom
    125,585 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following