|
How do I get WDSC to help pinpoint the "CPD0877: WHEN, OTHERWISE, or
ENDSELECT command expected." error in the following:
DoUntil (&TapChkLoop='1')
CHKTAP DEV(&TapeDrive) ENDOPT(*REWIND)
MONMSG MSGID(CPF0000)
RCVMSG MSGQ(*PGMQ) MSG(&Msg) MSGDTA(&MsgDta) MSGID(&MsgId) +
MSGTYPE(*LAST)
Select
When (&MsgId = 'CPC6778') Then(DO)
/* Volume &2 found on device &1. CHKTAP found a volume id loaded
*/
/* Is it the one we want? */
CHGVAR VAR(&VolId) VALUE(%SST(&MsgDta 11 6))
Select
When COND(%SST(&VolId 1 1) *EQ &Prefix) THEN(DO)
/* We got our tape, let's go on */
ChgVar &TapChkLoop '1'
EndDo
Otherwise (DO)
/* Not the right tape for this backup. Kick it out and hope the
right one loads. */
CHKTAP DEV(&TapeDrive) ENDOPT(*UNLOAD)
EndDo /* Volid was NOT the right one for this backup */
EndSelect /* Checking the volumne id prefix */
EndDo /* CHKTAP found a tape. CPC6778 */
When (&MsgId = 'ROB0000') Then(DO)
/* We've ejected every tape in the drive and have not yet found one
- abort */
ChkTapPgm TapeDrive(&TapeDrive) /* Alert the team */
ChgVar &TapChkLoop '1'
GoTo END
EndDo
EndSelect /* Checking messages as a result of the CHKTAP */
EndDo /* Loop until &TapChkLoop = '1' */
Rob Berendt
--
Group Dekko Services, LLC
Dept 01.073
PO Box 2000
Dock 108
6928N 400E
Kendallville, IN 46755
http://www.dekko.com
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.