Buggy code:
class CreateAliasConstantAction extends DDLConstantAction { private final String aliasName ; private final String schemaName ; private final String javaClassName ; private final char aliasType ; private final char nameSpace ; private final AliasInfo aliasInfo ; CreateAliasConstantAction ( String aliasName , String schemaName , String javaClassName , AliasInfo aliasInfo , char aliasType ) { } public String toString ( ) { } public void executeConstantAction ( Activation activation ) throws StandardException { LanguageConnectionContext lcc ; if ( activation != null ) { lcc = activation . getLanguageConnectionContext ( ) ; } else { lcc = ( ( LanguageConnectionContext ) ( ContextService . getContext ( CONTEXT_ID ) ) ) ; } DataDictionary dd = lcc . getDataDictionary ( ) ; TransactionController tc = lcc . getTransactionExecute ( ) ; String checkMethodName = null ; String checkClassName = javaClassName ; if ( ( aliasInfo ) != null ) checkMethodName = aliasInfo . getMethodName ( ) ; switch ( aliasType ) { case AliasInfo . ALIAS_TYPE_PROCEDURE_AS_CHAR : case AliasInfo . ALIAS_TYPE_FUNCTION_AS_CHAR : case AliasInfo . ALIAS_TYPE_SYNONYM_AS_CHAR : break ; default : { ClassFactory cf = lcc . getLanguageConnectionFactory ( ) . getClassFactory ( ) ; Class realClass = null ; try { realClass = cf . loadApplicationClass ( checkClassName ) ; <START_BUG> } catch ( Throwable t ) { <END_BUG> throw StandardException . newException ( LANG_TYPE_DOESNT_EXIST2 , t , checkClassName ) ; } if ( ! ( Modifier . isPublic ( realClass . getModifiers ( ) ) ) ) { throw StandardException . newException ( LANG_TYPE_DOESNT_EXIST2 , checkClassName ) ; } if ( checkMethodName != null ) { Method [ ] methods = realClass . getMethods ( ) ; int index = 0 ; for ( ; index < ( methods . length ) ; index ++ ) { if ( ! ( Modifier . isStatic ( methods [ index ] . getModifiers ( ) ) ) ) { continue ; } if ( checkMethodName . equals ( methods [ index ] . getName ( ) ) ) { break ; } } if ( index == ( methods . length ) ) { throw StandardException . newException ( LANG_NO_METHOD_MATCHING_ALIAS , checkMethodName , checkClassName ) ; } } } } dd . startWriting ( lcc ) ; SchemaDescriptor sd = null ; if ( activation == null ) sd = dd . getSysIBMSchemaDescriptor ( ) ; else if ( ( schemaName ) != null ) sd = DDLConstantAction . getSchemaDescriptorForCreate ( dd , activation , schemaName ) ; UUID aliasID = dd . getUUIDFactory ( ) . createUUID ( ) ; AliasDescriptor ads = new AliasDescriptor ( dd , aliasID , aliasName , ( sd != null ? sd . getUUID ( ) : null ) , javaClassName , aliasType , nameSpace , false , aliasInfo , null ) ; switch ( aliasType ) { case AliasInfo . ALIAS_TYPE_PROCEDURE_AS_CHAR : case AliasInfo . ALIAS_TYPE_FUNCTION_AS_CHAR : { List list = dd . getRoutineList ( sd . getUUID ( ) . toString ( ) , aliasName , aliasType ) ; for ( int i = ( list . size ( ) ) - 1 ; i >= 0 ; i -- ) { AliasDescriptor proc = ( ( AliasDescriptor ) ( list . get ( i ) ) ) ; RoutineAliasInfo procedureInfo = ( ( RoutineAliasInfo ) ( proc . getAliasInfo ( ) ) ) ; int parameterCount = procedureInfo . getParameterCount ( ) ; if ( parameterCount != ( ( ( RoutineAliasInfo ) ( aliasInfo ) ) . getParameterCount ( ) ) ) continue ; throw StandardException . newException ( LANG_OBJECT_ALREADY_EXISTS , ads . getDescriptorType ( ) , aliasName ) ; } } break ; case AliasInfo . ALIAS_TYPE_SYNONYM_AS_CHAR : TableDescriptor targetTD = dd . getTableDescriptor ( aliasName , sd ) ; if ( targetTD != null ) { throw StandardException . newException ( LANG_OBJECT_ALREADY_EXISTS , targetTD . getDescriptorType ( ) , targetTD . getDescriptorName ( ) ) ; } String nextSynTable = ( ( SynonymAliasInfo ) ( aliasInfo ) ) . getSynonymTable ( ) ; String nextSynSchema = ( ( SynonymAliasInfo ) ( aliasInfo ) ) . getSynonymSchema ( ) ; SchemaDescriptor nextSD ; for ( ; ; ) { nextSD = dd . getSchemaDescriptor ( nextSynSchema , tc , false ) ; if ( nextSD == null ) break ; AliasDescriptor nextAD = dd . getAliasDescriptor ( nextSD . getUUID ( ) . toString ( ) , nextSynTable , nameSpace ) ; if ( nextAD == null ) break ; SynonymAliasInfo info = ( ( SynonymAliasInfo ) ( nextAD . getAliasInfo ( ) ) ) ; nextSynTable = info . getSynonymTable ( ) ; nextSynSchema = info . getSynonymSchema ( ) ; if ( ( aliasName . equals ( nextSynTable ) ) && ( schemaName . equals ( nextSynSchema ) ) ) throw StandardException . newException ( LANG_SYNONYM_CIRCULAR , aliasName , ( ( SynonymAliasInfo ) ( aliasInfo ) ) . getSynonymTable ( ) ) ; } if ( nextSD != null ) targetTD = dd . getTableDescriptor ( nextSynTable , nextSD ) ; if ( ( nextSD == null ) || ( targetTD == null ) ) activation . addWarning ( StandardException . newWarning ( LANG_SYNONYM_UNDEFINED , aliasName , ( ( nextSynSchema + "." ) + nextSynTable ) ) ) ; TableDescriptor td ; DataDescriptorGenerator ddg = dd . getDataDescriptorGenerator ( ) ; td = ddg . newTableDescriptor ( aliasName , sd , SYNONYM_TYPE , DEFAULT_LOCK_GRANULARITY ) ; dd . addDescriptor ( td , sd , SYSTABLES_CATALOG_NUM , false , tc ) ; default : break ; } dd . addDescriptor ( ads , null , SYSALIASES_CATALOG_NUM , false , lcc . getTransactionExecute ( ) ) ; } }

Fix:
} catch ( ClassNotFoundException t ) {