概述
error_context()
error_message()
error_number()
error_timestamp()
Define the actions to take for each exception group and add the actions to the catch work flow box.
The actions can be an individual script, a data flow, a work flow, or any combination of these objects.
a. It is recommended that you define, test, and save the actions as a separate object rather than
constructing them inside the catch editor.
b. If you want to define actions for specific errors, use the following catch functions in a script that
the work flow executes:
• error_context()
• error_message()
• error_number()
• error_timestamp()
c. To add an existing work flow to the catch work flow box, open the object library to the Work Flows
tab, select the desired work flow, and drag it into the box.
Categories of available exceptions include:
• Execution errors (1001)
• Database access errors (1002)
• Database connection errors (1003)
• Flat file processing errors (1004)
• File access errors (1005)
• Repository access errors (1006)
• SAP system errors (1007)
• System resource exception (1008)
• SAP BW execution errors (1009)
• XML processing errors (1010)
• COBOL copybook errors (1011)
• Excel book errors (1012)
• Data Quality transform errors (1013)
Example: Catching details of an error
This example illustrates how to use the error functions in a catch script. Suppose you want to catch
database access errors and send the error details to your support group.
1. In the catch editor, select the exception group that you want to catch. In this example, select the
checkbox in front of Database access errors (1002).
2. In the work flow area of the catch editor, create a script object with the following script:
mail_to('support@my.com',
'Data Service error number' || error_number(),
'Error message: ' || error_message(),20,20);
print('DBMS Error: ' || error_message());
3. This sample catch script includes the mail_to function to do the following:
• Specify the email address of your support group.
• Send the error number that the error_number() function returns for the exception caught.
• Send the error message that the error_message() function returns for the exception caught.
4. The sample catch script includes a print command to print the error message for the database error.
-------------------------------------------------------------------------------------------------------------------------------------------------
I send all the parameters have no problem with that, the function is:
$message_text = SQL('BNF', 'SELECT 'COD_INDICADOR: '||CODINDICADOR||' INDICADOR: '||INDICADOR ||' ERROR: '|| DI_ERRORCOLUMNS FROM BNF_ERROR_INDICADOR where DBMS_ROWID.ROWID_ROW_NUMBER(rowid)={$count} ');
$sms = smtp_to($address_list,$subject_text,$message_text, 0,0);
in the body of the email I have the following result:
COD_INDICADOR: BNF-0200070
INDICADOR: Cartera De Cr??ditos Para La Microempresa Por Vencer
ERROR: Tipo_Indicador failed rule(s): CODTIPOINDICADOR
COD_INDICADOR: BNF-0200080
INDICADOR: Carteras De Cr??ditos Reestructuradas
ERROR: Tipo_Indicador failed rule(s):
Pasted from <http://businessintelligence.ittoolbox.com/groups/technical-functional/businessobjects-dataintegration-l/send-email-using-the-function-in-data-integrator-smtp_to-3264198
>
最后
以上就是俊秀项链为你收集整理的SAP Data Service Error Function的全部内容,希望文章能够帮你解决SAP Data Service Error Function所遇到的程序开发问题。
如果觉得靠谱客网站的内容还不错,欢迎将靠谱客网站推荐给程序员好友。
本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
发表评论 取消回复