Can ESB handle SOAP 1.2?
I have a routing service which is defined based on a schema. If i sent the following message all goes well:
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<soap:Body>
<kennisgevingsBericht xmlns="http://www.egem.nl/StUF/sector/bg/0204">
...... XML .....
</kennisgevingsBericht>
</soap:Body>
</soap:Envelope>
I now have an application generating a SOAP 1.2 specs message and then it errors. The message is like:
<soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<soap:Body>
<kennisgevingsBericht xmlns="http://www.egem.nl/StUF/sector/bg/0204">
...... XML .....
</kennisgevingsBericht>
</soap:Body>
</soap:Envelope>
Everything is the same except the xmlns:soap namespace references the soap 1.2 spec. It results in the error:
java.security.PrivilegedActionException: javax.xml.soap.SOAPException: Unable to get header stream in saveChanges
Does an esb routing service support soap 1.2 and how can i implement that?
Kind Regards,
Andre Jochems
http://blogs.oracle.com/reynolds/2007/05/17
soap 1.2 uses different headers..so guess thats where the esb gets stuck
Similar Messages
-
XMLSignature.validate - can it handle SOAP Message
hi,
can we verify a xml file where the xml signature has a certificate with the public key for verification
import weblogic.webservice.core.soap.XMLSignature;
FileInputStream fis = new FileInputStream("c:\\my.xml");
res = XMLSignature.validate(fis);
======== this is xml ==========
<Infringements><Signature xmlns="http://www.w3.org/2000/09/xmldsig#">
<SignedInfo>
<CanonicalizationMethod Algorithm="http://www.w3.org/TR/2001/REC-xml-c14n-20010315"></CanonicalizationMethod>
<SignatureMethod Algorithm="http://www.w3.org/2000/09/xmldsig#rsa-sha1"></SignatureMethod>
<Reference URI="">
<Transforms>
<Transform Algorithm="http://www.w3.org/2000/09/xmldsig#enveloped-signature"></Transform>
</Transforms>
<DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha1"></DigestMethod>
<DigestValue>Ibk/s94reaUTFYU6mwV0isxj6es=</DigestValue>
</Reference>
</SignedInfo>
<SignatureValue>
GRPQiCi+OSEx/ARw14uK+2GeIQQVDaXsUQWTxqMNp+qt3nGE7G7gkOxAU6k85rMplQ0KCliAJSO+
U5UJgTHE7ltqe2B+N0d16xNJAQYJqtilpGTmHFT63SvRqJIXJ8nqNxxRLcMOFSDSJ9uQ4svXZm1d
0LUT39+4x1KD2eL0c6c=
</SignatureValue>
<KeyInfo>
<X509Data>
<X509Certificate>
MIIC3zCCApWgAwIBAgIERCsMuTAJBgcqhkjOPQQBMB4xCzAJBgNVBAoTAkNBMQ8wDQYDVQQLEwZy
b290Y2EwHhcNMDYwNzI1MjMwNDAwWhcNMDkwNzI1MjMzNDAwWjBDMQ8wDQYDVQQKEwZDT1VSVFMx
EDAOBgNVBAsTB0NFTlRSQUwxDTALBgNVBAsTBFdHVE4xDzANBgNVBAMTBlJFTkRFRTCBoDANBgkq
hkiG9w0BAQEFAAOBjgAwgYoCgYEAtobxvMc6NXHiyAEGc9F2vybRXG7+W2yEgW3jrPyGX/iY0Q+l
NZSdUtzwGHMMmOMZQeydQGaGrcv6aWaj/Ropnh93IwurJfyQ8KKnTHV3Psc/2ka1lgJie+Vz53iY
kRSnYTtWd/Q0p7kp8qu4FW7FBJ/ko8d3I6DvebwpJ9hi6TUCBACUm82jggFTMIIBTzALBgNVHQ8E
BAMCB4AwKwYDVR0QBCQwIoAPMjAwNjA3MjUyMzA0MDBagQ8yMDA4MDgzMTAzMzQwMFowIgYDVR0R
BBswGYEXRGVlLlJlbkBqdXN0aWNlLmdvdnQubnowgYgGA1UdHwSBgDB+MDWgM6AxpC8wLTELMAkG
A1UEChMCQ0ExDzANBgNVBAsTBnJvb3RjYTENMAsGA1UEAxMEQ1JMMTBFoEOgQYY/bGRhcDovLzEw
LjE3Ni4xLjEvb3U9cm9vdGNhLG89Q0E/Y2VydGlmaWNhdGVSZXZvY2F0aW9uTGlzdD9iYXNlMB8G
A1UdIwQYMBaAFAYzTcM4Vtn7ikDcuLwITTKFYDJJMB0GA1UdDgQWBBR67rXz6zLs4M6HgC/TUr+S
uFlkxDAJBgNVHRMEAjAAMBkGCSqGSIb2fQdBAAQMMAobBFY3LjEDAgSwMAkGByqGSM49BAEDOQAw
NgIZAL/CPVyvKJ3XoueG2TzEQj4mDPPOqt25AQIZAL+wwlrjsngEQO2BW4pusMexLkT1E1WQmw==
</X509Certificate>
</X509Data>
<KeyValue>
<RSAKeyValue>
<Modulus>
tobxvMc6NXHiyAEGc9F2vybRXG7+W2yEgW3jrPyGX/iY0Q+lNZSdUtzwGHMMmOMZQeydQGaGrcv6
aWaj/Ropnh93IwurJfyQ8KKnTHV3Psc/2ka1lgJie+Vz53iYkRSnYTtWd/Q0p7kp8qu4FW7FBJ/k
o8d3I6DvebwpJ9hi6TU=
</Modulus>
<Exponent>lJvN</Exponent>
</RSAKeyValue>
</KeyValue>
</KeyInfo>
</Signature></Infringements>
Any help will be appreiciated.
I tried and it fails with weblogic.webservice.core.soap.XMLSignatureInvalidException: Signature invalid: 0 length SecurityAssersionhttp://blogs.oracle.com/reynolds/2007/05/17
soap 1.2 uses different headers..so guess thats where the esb gets stuck -
I am following this tutorial to handle SOAP responses but it does not work http://livedocs.adobe.com/flex/3/html/help.html?content=data_access_6.html
using code blew I am trying to parse the following soap response.
<?xml version="1.0" encoding="utf-8"?>
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:mx="library://ns.adobe.com/flex/mx"
xmlns:components="components.*"
xmlns:hellos="services.hellos.*"
height="957" creationComplete="initApp()" >
<fx:Style source="Styles.css"/>
<fx:Script>
<![CDATA[
import mx.controls.Alert;
private namespace invesbot = "http://Services.com";
use namespace invesbot;
private namespace a = "http://schemas.xmlsoap.org/soap/envelope/";
private namespace b = "http://www.w3.org/2001/XMLSchema";
private namespace c = "http://www.w3.org/2001/XMLSchema-instance";
use namespace a;
use namespace b;
use namespace c;
[Bindable]
var _result:*
private function initApp():void
myService.mycustomers();
]]>
</fx:Script>
<fx:Declarations>
<mx:WebService id="myService" wsdl="http://localhost:8081/WebServiceTest/services/Hellos?wsdl"
showBusyCursor="true"
fault="Alert.show(event.fault.faultString), 'Error'">
<mx:operation name="mycustomers" resultFormat="e4x">
<mx:request>
</mx:request>
</mx:operation>
</mx:WebService>
</fx:Declarations>
<mx:HBox>
<mx:Text
text="{myService.mycustomers.lastResult.mycustomersReturn.name}"
/>
</mx:HBox>
</s:Application>
The SOAP response is as following
<?xml version="1.0" encoding="UTF-8"?>
<soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<soapenv:Body>
<mycustomersResponse xmlns="http://Services.com">
<mycustomersReturn>
<age>28</age>
<name>John</name>
</mycustomersReturn>
<mycustomersReturn>
<age>29</age>
<name>Alex</name>
</mycustomersReturn>
<mycustomersReturn>
<age>30</age>
<name>Jack</name>
</mycustomersReturn>
</mycustomersResponse>
</soapenv:Body>
</soapenv:Envelope>
Using the above code the output will be
<name xmlns="http://Services.com" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">John</name>
<name xmlns="http://Services.com" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">Alex</name>
<name xmlns="http://Services.com" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">Jack</name>
but when I use the following code to put the result in dropdown box it gives the following error
<s:FormItem label="Employee:">
<s:DropDownList id="dropDownList3"
labelField="name"
dataProvider ="{myService.mycustomers.lastResult.mycustomersReturn}"/>
</s:FormItem>
TypeError: Error #1034: Type Coercion failed: cannot convert XMLList@106e9af1 to mx.collections.IList.Hi Ashish,
You can use Catch All error handler within scope of InvokeService action. By specifying SOAP Fault variable name there, response soap fault will be populated in variable.
In 11g(As per observation), split joins are strict towards definition of input and output message based on WSDL of target service which causes exception for invalidMessage in InvokeService action.
Hope this helps. -
Can FDM handle more than one year at a time?
Hi,
I'm trying to load a multi-load file through FDM with the target being an Essbase cube and the source being a text file. The file is for 36 months which crosses 3 years. The problem is Oracle support is saying FDM can only handle one calendar year at a time and we need to load 3 separate files.
The file imports and validates ok. And the export only pushes data to the first year '2010' but it doesn't error out.
Any ideas?If you use an excel file as the source, you can load all 36 periods.
You can also modify the adaptor to support this action but I would caution you that doing so will cause support to no longer support your application without requiring you to import a non customized adaptor. This also has consequences for when upgrading.
Let me add, FDM support is the best in the business. I have never had a situation where what they told me was incorrect. What you are trying to accomplish would be a custom solution that should be implemented by an experienced FDM resource that understands the impact of the customization.
Edited by: TonyScalese on May 6, 2010 3:10 PM -
How the material PRT issue/receipt to the production order can be handled?
Hi PP Gurus,
For one of our clients, the handling of PRT is to be controlled with the issue/receipt for the production order.
1. What is the procedure for issue/receipt of PRT material in the SAP?
2. What is the procedure to block the PRT for the creation/release of production order when it was already assigned to the other production order during the same time?
3. The PRT is to be available automatically once the assigned production order operation is confiremd.How it can be handled in the SAP?
Appreciate your early response.
Thanks,
Reddy.Hi Ramanujam,
Thanks for your response.
1. The dies can be used for the production of Pressing, Casting and Forging etc. These dies will be managed in the stores. The stores representatives will issue the die to the shop floor for an operation of a production order.They will return back the die once the production is completed at that operation using the die. How to map this process in the SAP.
Typically, these dies can be treated as PRT materials in the SAP system.
2. OPJK configuration is not sufficient. The same PRT will be assigned to the many production orders during the same time.The system won't block with only this setting. There are some other steps involved to complete the process.
I would like to know the complete procedure with all the steps to block the PRT once it was assigned to the production order operation. The same PRT is to be available for other production orders automatically once the operation is confirmed after production. -
How can we handle browser settings while dealing with the security ?
Hi ,
how can we handle browser settings while dealing with the security ?When we configured security in web.xml , during the first request the container is asking for the authentication credentials once they are provided it go's on. but when the user gives a fresh request from the second window within the same browser that time it is not asking for authentication. How can we overcome this.Is there anything to do with server configurations?
How can we make the container no to keep the things or act like session?Ya... I am taking a small example need not happen always but a kind of possibility i am thinking off.
once the user sign out and just left without closing the browser and a friend (suppose not a good friend ... just kidding...) of that user may open the same jsp or file .This time the security is breached. If that feature or property exists....
I know what you might say ... the user will log-out before leaving where a programer might invalidate the session at the time of log out.
Consider the case of a bad Programing or just a programer might forget to invalidate,At that time as a application administrator how can he solve that issue.
Thanks.......
Edited by: user8483670 on Jun 6, 2011 1:08 AM
Edited by: user8483670 on Jun 6, 2011 1:09 AM -
I loaded mountain lion and now my computer can't handle video or load iTunes
I loaded mountain lion and now my computer can't handle video or load itunes
4 GB ram
2.4 GH processor
I have 3 topics in the activity monitor running at 9995 Mb real memory
loginwindow = 952 mb
systemUIServer = 950 mb
usereventagent = 940mb
has mountain lion just ate up my ram in operations -
Can we handle exceptions for the expressions in select query?
Hi all,
Can we handle exceptions for the expressions in select query.
I created a view, there I am extracting a substring from a character data and expected that as a number.
For example consider the following query.
SQL> select to_number( substr('r01',2,2) ) from dual;
TO_NUMBER(SUBSTR('R01',2,2))
1
Here we got the value as "1".
Consider the following query.
SQL> select to_number( substr('rr1',2,2) ) from dual;
select to_number( substr('rr1',2,2) ) from dual
ORA-01722: invalid number
For this I got error. Because the substr returns "r1" which is expected to be as number. So it returns "Invalid number".
So, without using procedures or functions can we handle these type of exceptions?
I am using Oracle 10 G.
Thanks in advance.
Thank you,
Regards,
Gowtham Sen.SQL> select decode(ltrim(rtrim(translate(substr('r21', 2, 2), '0123456789', ' ' ), ' '), ' '), null, (substr('r21', 2, 2)), null) from dual;
DE
21
SQL> ed a
SQL> select decode(ltrim(rtrim(translate(substr('rr1', 2, 2), '0123456789', ' ' ), ' '), ' '), null, (substr('rr1', 2, 2)), null) from dual;
D
- -
In-Context Editor can't handle implicit index.html
The In-Context Editor can't handle implicit index.html - e.g., when a menu link points to /subfolder/ with a file named index.html inside, the link works fine on the front-end but In-Context Editor users get a 404 Page Not Found error.
Naively, it appends .htm to the folder, producing an invalid url like this: /subfolder/.htm
The workaround is to explicitly include the filename in the link like /subfolder/index.html, but this is undesirable.
Anyone else been bitten by this?/subfolder
Will go to the same place as well. -
How can you handle Third Party Payment in Oracle Payroll
People I hope you all are at your Good Health!
I have a question and that is i would like to know how i can restrict a dependent from getting an Insurance benefit after he has crossed the Age =18 Also the To date must be calculated and populated automatically.
Also, how can we handle this third party payment in the Oracle Payroll.
All comments are welcomed.
ChetanFor the payment piece, create a payment method on the person record as a third party. you would need to have setup the recieving party as a third party organization before setting up at employee level.
During normal payroll processing, you may run Third party check writer to generate a check .
Ankur thank you for the response i have understood that we must create a Payment Method and Check the Check box for Third party Payment on Payment Method window.But how will that be handled for case where an employee has taken a Loan from a Bank and he has to be deducted every month from his salary how can we handle such a requiremet.
I did not understand when you said :
"you would need to have setup the recieving party as a third party organization before setting up at employee level.
During normal payroll processing, you may run Third party check writer to generate a check ."
Could you please explain me.
Regards,
Chetan -
hello,
I created a java control which calls an external webservice. How do you handle
SOAP fault messages coming back from the webservice?
Weblogic just throws an java.lang.reflect.UndeclaredThrowableException since it
cannot parse the expected XML message.
For example, when I call Logon() via the java control. The WebService should
reply with a LogonResult object(in xml format). However, if there's an error,
the WebService returns a SOAP Fault message. Since this fault message is not
in the format of the expected LogonResult xml schema, weblogic throws an error
(since it cannot create the LogonResult object) and the caller just receives the
UndeclaredThrowableException without knowing any of the contents within the SOAP
Fault.
I'd like to be able to send back the SOAP fault content back to the calling function.
I've tried throwing an exception from the java control handler, but it gets swallowed
up by the SOAP Handler so I still get an exception with no content.
any info is appreciated.
thanks,
TomHi,
Do you get answer for that?
I had similar problem and solved this in this way:
In this java.lang.reflect.UndeclaredThrowableException handler is possible to get also SoapFault back:
catch (java.lang.reflect.UndeclaredThrowableException e){
RemoteException re = (RemoteException).getUndeclaredThrowable();
ServiceControlException sfe = (ServiceControlException)re.getCause();
SoapFault fault = sfe.getSoapFault();
XmlObject[] objs = fault.getDetailContents();
// more procssing here to get Soap detailed error
Maybe this helps.
rgrds,
H -
How can we handle multiple applications in session method
how can we handle multiple applications in .. session method.
can any body reply me.
thanksHari,
hi Check out this sample code to use session method
REPORT ztest_report
NO STANDARD PAGE HEADING
LINE-SIZE 255
MESSAGE-ID ZRASH.
Internal Table Declarations *
*--Internal Table for Data Uploading.
DATA : BEGIN OF IT_FFCUST OCCURS 0,
KUNNR(10),
BUKRS(4),
KTOKD(4),
ANRED(15),
NAME1(35),
SORTL(10),
STRAS(35),
ORT01(35),
PSTLZ(10),
LAND1(3),
SPRAS(2),
AKONT(10),
END OF IT_FFCUST.
*--Internal Table to Store Error Records.
DATA : BEGIN OF IT_ERRCUST OCCURS 0,
KUNNR(10),
EMSG(255),
END OF IT_ERRCUST.
*--Internal Table to Store Successful Records.
DATA : BEGIN OF IT_SUCCUST OCCURS 0,
KUNNR(10),
SMSG(255),
END OF IT_SUCCUST.
*--Internal Table for Storing the BDC data.
DATA : IT_CUSTBDC LIKE BDCDATA OCCURS 0 WITH HEADER LINE.
*--Internal Table for storing the messages.
DATA : IT_CUSTMSG LIKE BDCMSGCOLL OCCURS 0 WITH HEADER LINE.
DATA : V_FLAG1(1) VALUE ' ',
"Flag used for opening session.
V_TLINES LIKE SY-TABIX,
"For storing total records processed.
V_ELINES LIKE SY-TABIX,
"For storing the no of error records.
V_SLINES LIKE SY-TABIX.
"For storing the no of success records.
Selection screen *
SELECTION-SCREEN BEGIN OF BLOCK B1.
PARAMETERS : V_FNAME LIKE RLGRAP-FILENAME,
V_SESNAM LIKE RLGRAP-FILENAME.
SELECTION-SCREEN END OF BLOCK B1.
Start-of-selection *
START-OF-SELECTION.
*-- Form to upload flatfile data into the internal table.
PERFORM FORM_UPLOADFF.
TOP-OF-PAGE *
TOP-OF-PAGE.
WRITE:/ 'Details of the error and success records for the transaction'
ULINE.
SKIP.
End of Selection *
END-OF-SELECTION.
*-- Form to Generate a BDC from the Uploaded Internal table
PERFORM FORM_BDCGENERATE.
*--To write the totals and the session name.
PERFORM FORM_WRITEOP.
*& Form form_uploadff
Form to upload flatfile data into the internal table.
FORM FORM_UPLOADFF .
*--Variable to change the type of the parameter file name.
DATA : LV_FILE TYPE STRING.
LV_FILE = V_FNAME.
*--Function to upload the flat file to the internal table.
CALL FUNCTION 'GUI_UPLOAD'
EXPORTING
FILENAME = LV_FILE
FILETYPE = 'ASC'
HAS_FIELD_SEPARATOR = 'X'
HEADER_LENGTH = 0
READ_BY_LINE = 'X'
DAT_MODE = ' '
IMPORTING
FILELENGTH =
HEADER =
TABLES
DATA_TAB = IT_FFCUST
EXCEPTIONS
FILE_OPEN_ERROR = 1
FILE_READ_ERROR = 2
NO_BATCH = 3
GUI_REFUSE_FILETRANSFER = 4
INVALID_TYPE = 5
NO_AUTHORITY = 6
UNKNOWN_ERROR = 7
BAD_DATA_FORMAT = 8
HEADER_NOT_ALLOWED = 9
SEPARATOR_NOT_ALLOWED = 10
HEADER_TOO_LONG = 11
UNKNOWN_DP_ERROR = 12
ACCESS_DENIED = 13
DP_OUT_OF_MEMORY = 14
DISK_FULL = 15
DP_TIMEOUT = 16
OTHERS = 17
IF SY-SUBRC = 0.
*--Deleting the headings from the internal table.
DELETE IT_FFCUST INDEX 1.
*--Getting the total number of records uploaded.
DESCRIBE TABLE IT_FFCUST LINES V_TLINES.
ENDIF.
ENDFORM. " form_uploadff
*& Form Form_bdcgenerate
Form to Generate a BDC from the Uploaded Internal table
FORM FORM_BDCGENERATE .
*--Generating the BDC table for the fields of the internal table.
LOOP AT IT_FFCUST.
PERFORM POPULATEBDC USING :
'X' 'SAPMF02D' '0105',
' ' 'BDC_OKCODE' '/00' ,
' ' 'RF02D-KUNNR' IT_FFCUST-KUNNR,
' ' 'RF02D-BUKRS' IT_FFCUST-BUKRS,
' ' 'RF02D-KTOKD' IT_FFCUST-KTOKD,
'X' 'SAPMF02D' '0110' ,
' ' 'BDC_OKCODE' '/00',
' ' 'KNA1-ANRED' IT_FFCUST-ANRED,
' ' 'KNA1-NAME1' IT_FFCUST-NAME1,
' ' 'KNA1-SORTL' IT_FFCUST-SORTL,
' ' 'KNA1-STRAS' IT_FFCUST-STRAS,
' ' 'KNA1-ORT01' IT_FFCUST-ORT01,
' ' 'KNA1-PSTLZ' IT_FFCUST-PSTLZ,
' ' 'KNA1-LAND1' IT_FFCUST-LAND1,
' ' 'KNA1-SPRAS' IT_FFCUST-SPRAS,
'X' 'SAPMFO2D' '0120',
' ' 'BDC_OKCODE' '/00',
'X' 'SAPMF02D' '0125',
' ' 'BDC_OKCODE' '/00',
'X' 'SAPMF02D' '0130',
' ' 'BDC_OKCODE' '=ENTR',
'X' 'SAPMF02D' '0340',
' ' 'BDC_OKCODE' '=ENTR',
'X' 'SAPMF02D' '0360',
' ' 'BDC_OKCODE' '=ENTR',
'X' 'SAPMF02D' '0210',
' ' 'KNB1-AKONT' IT_FFCUST-AKONT,
' ' 'BDC_OKCODE' '/00',
'X' 'SAPMF02D' '0215',
' ' 'BDC_OKCODE' '/00',
'X' 'SAPMF02D' '0220',
' ' 'BDC_OKCODE' '/00',
'X' 'SAPMF02D' '0230',
' ' 'BDC_OKCODE' '=UPDA'.
*--Calling the transaction 'fd01'.
CALL TRANSACTION 'FD01' USING IT_CUSTBDC MODE 'N' UPDATE 'S'
MESSAGES INTO IT_CUSTMSG.
IF SY-SUBRC <> 0.
*--Populating the error records internal table.
IT_ERRCUST-KUNNR = IT_FFCUST-KUNNR.
APPEND IT_ERRCUST.
CLEAR IT_ERRCUST.
*--Opening a session if there is an error record.
IF V_FLAG1 = ' '.
PERFORM FORM_OPENSESSION.
V_FLAG1 = 'X'.
ENDIF.
*--Inserting the error records into already open session.
IF V_FLAG1 = 'X'.
PERFORM FORM_INSERT.
ENDIF.
*--Populating the Success records internal table.
ELSE.
IT_SUCCUST-KUNNR = IT_FFCUST-KUNNR.
APPEND IT_SUCCUST.
CLEAR IT_SUCCUST.
ENDIF.
*--Displaying the messages.
IF NOT IT_CUSTMSG[] IS INITIAL.
PERFORM FORM_FORMATMSG.
ENDIF.
*--Clearing the message and bdc tables.
CLEAR : IT_CUSTBDC[],IT_CUSTMSG[].
ENDLOOP.
*--Getting the total no of error records.
DESCRIBE TABLE IT_ERRCUST LINES V_ELINES.
*--Getting the total no of successful records.
DESCRIBE TABLE IT_SUCCUST LINES V_SLINES.
*--Closing the session only if it is open.
IF V_FLAG1 = 'X'.
PERFORM FORM_CLOSESESS.
ENDIF.
ENDFORM. " Form_bdcgenerate
*& Form populatebdc
FOrm to Populate the BDC table.
FORM POPULATEBDC USING VALUE(P_0178)
VALUE(P_0179)
VALUE(P_0180).
IF P_0178 = 'X'.
IT_CUSTBDC-PROGRAM = P_0179.
IT_CUSTBDC-DYNPRO = P_0180.
IT_CUSTBDC-DYNBEGIN = 'X'.
ELSE.
IT_CUSTBDC-FNAM = P_0179.
IT_CUSTBDC-FVAL = P_0180.
ENDIF.
APPEND IT_CUSTBDC.
CLEAR IT_CUSTBDC.
ENDFORM. " populatebdc
*& Form FORM_OPENSESSION
Form to Open a session.
FORM FORM_OPENSESSION .
*--Variable to convert the given session name into reqd type.
DATA : LV_SESNAM(12).
LV_SESNAM = V_SESNAM.
*--Opening a session.
CALL FUNCTION 'BDC_OPEN_GROUP'
EXPORTING
CLIENT = SY-MANDT
GROUP = LV_SESNAM
HOLDDATE = '20040805'
KEEP = 'X'
USER = SY-UNAME
PROG = SY-CPROG
IMPORTING
QID =
EXCEPTIONS
CLIENT_INVALID = 1
DESTINATION_INVALID = 2
GROUP_INVALID = 3
GROUP_IS_LOCKED = 4
HOLDDATE_INVALID = 5
INTERNAL_ERROR = 6
QUEUE_ERROR = 7
RUNNING = 8
SYSTEM_LOCK_ERROR = 9
USER_INVALID = 10
OTHERS = 11
IF SY-SUBRC <> 0.
WRITE :/ 'Session not open'.
ENDIF.
ENDFORM. " FORM_OPENSESSION
*& Form FORM_INSERT
fORM TO INSERT ERROR RECOED INTO A SESSION.
FORM FORM_INSERT .
*--Inserting the record into session.
CALL FUNCTION 'BDC_INSERT'
EXPORTING
TCODE = 'FD01'
POST_LOCAL = NOVBLOCAL
PRINTING = NOPRINT
SIMUBATCH = ' '
CTUPARAMS = ' '
TABLES
DYNPROTAB = IT_CUSTBDC
EXCEPTIONS
INTERNAL_ERROR = 1
NOT_OPEN = 2
QUEUE_ERROR = 3
TCODE_INVALID = 4
PRINTING_INVALID = 5
POSTING_INVALID = 6
OTHERS = 7
IF SY-SUBRC <> 0.
WRITE :/ 'Unable to insert the record'.
ENDIF.
ENDFORM. " FORM_INSERT
*& Form FORM_CLOSESESS
Form to Close the Open Session.
FORM FORM_CLOSESESS .
CALL FUNCTION 'BDC_CLOSE_GROUP'
EXCEPTIONS
NOT_OPEN = 1
QUEUE_ERROR = 2
OTHERS = 3.
IF SY-SUBRC <> 0.
ENDIF.
ENDFORM. " FORM_CLOSESESS
*& Form FORM_FORMATMSG
Form to format messages.
FORM FORM_FORMATMSG .
*--Var to store the formatted msg.
DATA : LV_MSG(255).
CALL FUNCTION 'FORMAT_MESSAGE'
EXPORTING
ID = SY-MSGID
LANG = SY-LANGU
NO = SY-MSGNO
V1 = SY-MSGV1
V2 = SY-MSGV2
V3 = SY-MSGV3
V4 = SY-MSGV4
IMPORTING
MSG = LV_MSG
EXCEPTIONS
NOT_FOUND = 1
OTHERS = 2.
IF SY-SUBRC = 0.
WRITE :/ LV_MSG.
ENDIF.
ULINE.
ENDFORM. " FORM_FORMATMSG
*& Form form_writeop
To write the totals and the session name.
FORM FORM_WRITEOP .
WRITE :/ 'Total Records Uploaded :',V_TLINES,
/ 'No of Error Records :',V_ELINES,
/ 'No of Success Records :',V_SLINES,
/ 'Name of the Session :',V_SESNAM.
ULINE.
ENDFORM. " form_writeop
Don't forget to reward if useful.. -
How can I handle runtime errors in Java
Please some one tell me what are runtime errors and How can I handle them using java code
This is important
Thanks in Advance
Chowdary AKThe java equivalent of function pointers is the one-instance class, as used to pass handlers to swing components, for example. Often an anonymous class is used.
Put your function signature in an interface, and pass an object that implements that interface:
public Class1 {
public interface CallBack {
void myMethod(String arg1);
CallBack callb;
public Class1(CallBack callb) {
this.callb = callb;
callb.myMethod("A string");
class2 {
first = new Class1(new Class1.CallBack() {
public void myMethod(String arg1) {
... do something ... -
How can I handle exception? - to give user more friendly notification
Hi!
User gets an error:
'Error in mru internal routine: ORA-20001: Error in MRU: row= 1, ORA-20001: ORA-20001: Current version of data in database has changed since user initiated update process. current checksum =...'
How can I handle this exception (when two users want to modify the same set of data at the same time)? I would like to hide the above error message and give user more friendly notification.
Thanks in advance,
TomThanks Vikas for your answer.
These workarounds are really creative and I want to use one of them. BUT my problem is to 'catch' the exception/error when two users want to modify the same set of data at the same time.
Those solutions which we can read about in this link you gave me describe handling exceptions in pl/sql processes. How can I catch the error I am talking about in pl/sql code?
Code would be like this:
DECLARE
two_users EXCEPTION;
BEGIN
IF --catch the error
THEN RAISE two_users;
END IF;
EXCEPTION WHEN two_users
THEN :HIDDEN_ITEM := 'Error Message';
END;
What should I put in a place where there is '--catch the error' ??
Thanks in advance,
Tom -
Hi friends,
When a work item is created. The User hasn't Approved / Rejected (hasnt taken any Action on that workflow) for 2 days, 4 days and 6 days an Escalation mail has to sent to respective concerend persons.
How can we handle this. The holidays are only Saturday and Sunday.
Client doesnt want to consider the factory calender.
Please suggest me step by step
Thanks in Advance
GaneshYou need to make use of "Modelled Deadline Monitoring" to achieve ur requirement.
Trust me... Search this forum and you will find answer how to make use of different steps to achieve it....
Regards,
PR.
Maybe you are looking for
-
Problems booting from install disk with MacBook Air
(I'm posting this here b/c it's been three days since I posted this in the /MacBook Air/Networking section and no one's touched it...) Somehow, the hard disk in my MBA has been corrupted, or something. First symptom I noticed - when booting up, I get
-
Uploading docs from iPad to MacBook Pro via iCloud
Why are my Pages documents not syncing with iCloud, and what do I do about it? I have iCloud turned On, Documents and Data turned On to store on iCloud, I have 24.3 GB storage available, and I have Use iCloud turned On in Pages. What else do I have t
-
Cannot compile WWUTL_API_IMPORT_PAGEGROUP
Hi, When trying to compile the package WWUTL_API_IMPORT_PAGEGROUP, I get the following error message: The following error has occurred: PACKAGE BODY PORTAL.WWUTL_API_IMPORT_PAGEGROUP On line: 1083 PLS-00306: wrong number or types of arguments in call
-
Make field internal order mandatory in transaction f-90
Hi all! My customer wants to post to statistical internal order on all asset transactions (not only AUC) in transaction f-90. They want that field mandatory. They want to post it on the asset, not on the vendor. But I don't even see that field. How c
-
MM Configuration Materials Required
Hello Gurus, I am new MM and i would like to have some configuration documents in MM. Please send me the documents to my mail ID [email protected] I appreciate your help and i will award you points. with regards, mahesh