The alternate solution :
In the variable declaraion section
DECALRE DGTT_FOUND SMALLINT DEFAULT 0 ;
In the contine handler section, add an additional handler
DECLARE CONTINUE HANDLER FOR ‘42710’
SET DGTT_FOUND=1 ;
In the SP body
DECLARE GLOBAL TEMPERORY TABLE SESSION.T1 ( I INT) ;
IF (DGTT_FOUND=1) THEN
......
...
ELSE
.....
.....
END IF ;
Then depending on the value of DGTT variable you can decide what you want to do ... For checking the existence of a dgtt, make sure you do not use the 'WITH REPLACE' option
I have tried this on DB2 V8 on ZOS and works ... ( I had to code this continue handler because zos does not support the WITH REPLACE Option )... I don't see a reason why it will not work on LUW
HTH
Sathyaram