|
In an sql trigger, I'm trying to implement the ability to add a library
list entry...
I have the below code...
On the first invocation everything works fine and myLIB gets added to the
libl.
But on the second invocation, it still fails with SQLSTATE '38501' because
myLib is in the library list...
I would think when SQLSTATE 38501 is detected it would not fail but
CONTINUE with what is in the BEGIN/END... no? What am I missing?
BEGIN DECLARE CONTINUE HANDLER FOR SQLSTATE '38501'
CALL QSYS2.QCMDEXC('RMVLIBLE LIB(myLib)');
END;
CALL QSYS2.QCMDEXC('ADDLIBLE LIB(myLib) POSITION(*LAST)');
tia
Jay
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 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.