This method receives several parameters, including a SQL statement and a result handler, and returns an object of generic type t.
这个方法接收多个参数,包括一条sql语句和一个结果处理程序,并返回一个泛型t的对象。
If a statement in your SQL procedure raises an SQLWARNING or NOT FOUND condition and if you have declared a handler for the respective condition, DB2 passes control to the corresponding handler.
如果SQL过程中有一个语句发出SQLWARNING或NOTFOUND条件,并且为相应的条件声明了一个处理程序,那么DB 2将把控制转移到相应的处理程序。
If you have not declared a handler for a condition, DB2 passes control to the next statement in the SQL procedure body.
如果没有为条件声明处理程序,DB 2将把控制器传递到SQL过程体中的下一个语句。
Also, the response to each of the anticipated exceptions is to do nothing, but the CONTINUE HANDLER declaration expects a complete SQL statement; hence the dummy assignment.
另外,对于每种可能出现的异常的响应是不做任何事,但是CONTINUEHANDLER声明需要一个完整的sql语句;因此使用伪赋值。
If a statement raises a condition for which a handler exists, the values of the SQLSTATE and SQLCODE variables are available at the beginning of the handler execution.
如果某条语句发出一个存在处理程序的条件,那么SQLSTATE和SQLCODE变量的值就可以在开始执行处理程序时获得。
Note that the dummy variable declaration has disappeared: you don't need it because you now have an actual statement in the exception handler.
注意,伪变量声明已经没有了:不再需要它是因为现在在异常处理函数中有了实际的语句。
When the INSERT statement fails with the error code specified in the DECLARE exit handler statement, control passes to the handler, and the procedure is exited.
当insert语句失败并且错误代码在DECLAREEXIThandler语句中指定,那么控制将传递到处理程序,而过程将退出。
It is a common practice to copy the values of SQLSTATE and SQLCODE into local variables in the first statement of the handler, as shown in Listing 11.
将SQLSTATE和SQLCODE的值复制到处理程序的第一个语句的本地变量中,这是一种常见的做法,如清单11所示。
In the case of the DB2 example in the left column of Table 3, if a particular SQL statement fails and generates an error, control is passed to the condition handler.
对于表3左侧列的DB 2示例,如果某条sql语句失败并生成一个错误,那么控制将被传递给条件处理程序。
The statement will be used by our WSDL POST handler to keep track of all of the WSDL documents in the system.
我们的WSDLPOST处理程序将使用这条语句来跟踪系统中所有的WSDL文档。
The SIGNAL statement is used to explicitly raise an error and force the invocation of a handler.
signal语句用于显式地发出一个错误并强制调用处理程序。
For this article, I will be using a combination of fixed-list dynamic SQL and static embedded SQL (for the UPDATE statement) to create a format-based handler.
对于本文,我将结合使用固定列表动态sql和静态嵌入式SQL(用于update语句)来创建一个基于格式的Handlder程序。
For example, whenever referring to the adjuster's name in the trigger handler (specifically in the selector statement) or content adapter, use "AdjusterName."
例如,无论何时涉及到触发器处理程序(特别是在选择程序语句中)或者内容适配器中调整器的名称,都要使用“ AdjusterName。”
The statement-based handler is better suited for varying-list style dynamic SQL.
基于语句的 Handler程序更适合变动列表样式的动态 SQL。
The statement-based handler is better suited for varying-list style dynamic SQL.
基于语句的 Handler程序更适合变动列表样式的动态 SQL。
应用推荐