UDF Runtime Exeception

Dear all,
1)Let me know why the runtime exception is raised when the UDF in tested in the message/interface mappings.
if we import java/XSLT mappings to the External definations and if we use for testing it is working fine.
What is the difference ?
2)can you please send my some documents on SAX/DOM jave mappings.
my mailid:[email protected]
Thanks,
SrinivasaPhani

Hi
refr these links for
Java mapping using SAX parser 
/people/prasad.ulagappan2/blog/2005/06/29/java-mapping-part-i
/people/prasad.ulagappan2/blog/2005/06/29/java-mapping-part-ii
more @ https://www.sdn.sap.com/irj/sdn/wiki?path=/display/xi/javaMappingSample+Code&
check this blog for SAX parsing
/people/thorsten.nordholmsbirk/blog/2006/08/10/using-jaxp-to-both-parse-and-emit-xml-in-xi-java-mapping-programs
Processing Large XML Documents Using SAX 2.0
http://www.oreillynet.com/pub/a/oreilly/xml/news/xmlnut4_0501.html
SAX programming examples
http://xerces.apache.org/xerces2-j/samples-sax.html
Programming the SAX interface
http://www.ibm.com/developerworks/xml/library/x-wxxm11.html
DOM mapping using SAX parser 
have a look - https://www.sdn.sap.com/irj/sdn/wiki?path=/display/xi/java%2bmapping%2busing%2bdom%2bparser
for DOM Parsing
http://java.sun.com/j2se/1.4.2/docs/api/org/w3c/dom/package-frame.html
/people/thorsten.nordholmsbirk/blog/2006/08/10/using-jaxp-to-both-parse-and-emit-xml-in-xi-java-mapping-programs
For a tutorial on the methods of SAX and DOM http://java.sun.com/webservices/docs/1.1/tutorial/doc/
The following websites give details regarding Java Mapping using DOM parser :
Excellent website showing how 2 use Document Object Model (DOM)
http://www.w3.org/DOM/
Document Object Model (DOM) Parsing
http://www.xml.com/lpt/a/1597
Overview of DOM, DOM Level 3 core,DOM Level 3 Load & Save
http://www.softwaresummit.com/2004/speakers/GrahamJAXP1.pdf
Sample java program using DOM
http://mail-archives.apache.org/mod_mbox/cocoon-cvs/200305.mbox/%[email protected]%3Eorg/mod_mbox/cocoon-cvs/200305.mbox/%[email protected]%3E
Easy RFC lookup from XSLT mappings using a Java helper class
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/05a3d62e-0a01-0010-14bc-adc8efd4ee14
XML Transformation Using the TrAX APIs in JAXP
http://www.xml.com/pub/a/2005/07/06/jaxp.html?page=last
Regards
Abhishek

Similar Messages

  • Runtime exeception after deploying PAR file in portal

    Hi ,
    I am facing an issue during the deployment of PAR file in our  Quality portal. I have download the PAR file from the system-->import to the NWDS--> did the modification (only to the properties files as part of my requirement) -->Export as PAR file. I then undeploy the previous earlier PAR file and then upload the modified PAR file in portal. When i test the application , i received portal runtime error.
    I have also tried by downloading the PAR file for the same application from the production portal and tried importing to Quality system without making any modification to the PAR. I still face the same issue.
    Due to this issue, i am not able to bring the application back as its not getting deployed properly. Can anyone help me on this.
    Regards
    Ray

    Hi Ray,
    Are you sure your file is getting deployed properly. Can you verify if the time stamp of the PAR file is getting updated on each deployment or after you upload it through Portal.
    Also, please check the PAR file (size and it's contents by unzipping the PAR file) that you've downloaded from PROD and deploying on QAS to ensure that the file is not corrupted by any means during downloading.
    You can also ask your BASIS team to provide the PAR file directly from PROD server and try to upload it on QAS instead of you downloading it from PROD portal.
    Also, you can follow the below steps to download the PAR file yourself from PROD portal with Administrator ID:
    Browse to the following location : System administration->Support->Portal Runtime->Browse deployment->ROOT/WEB-INF/deployment/temp
    1. Find and Identify the PAR file and Copy the name of PAR file.
    2. Click on view instead of download link to save the PAR file. Keep the name of PAR file same while saving with .par extension.
    3. Deploy this file on QAS Portal.
    Please let us know the results.
    BR,
    Anurag

  • When we wil go for abap mapping ??

    Hi,
    As we know there are graphical, XSLT, JAVA mappings are there apart from ABAP mapping. I have gone through below weblog.
    /people/udo.martens/blog/2006/08/23/comparing-performance-of-mapping-programs
    and also help.
    http://help.sap.com/saphelp_nw04/helpdata/en/12/05731a10264057badc32d3d3957015/frameset.htm
    None of them says ABAP mapping is either faster or stable as compared to other mappings. Even though it is the case, still when we will go for abap mapping ??
    Is it like that it is totally depend on the available resources in hand ??
    thanks
    kumar

    > The SAP XI/PI mapping is the most efficient as it
    > only loads the part of the source message that are
    > used to create the target message(s) at runtime.
    >
    > Java and XSLT have to load the whole message into
    > memory to process the message. This can be
    > inefficient and if dealing with large messages can
    > cause issues.
    About your statement.
    If you consider the field mapping (or UDF) runtime, then you are correct. But if you consider the whole mapping runtime, you also have to "load" the full message in message mapping, obviously. What happens is that it is transparent to the developer, since loading and parsing is done by standard. But message mapping also deals with loading and parsing the whole message (and it is done with Java underneath). Then I don't think message mapping will have a significantly better/worse performance, when compared with Java mappings (performing normal xml processing methods).
    As for XSLT, the performance problems happens because you have a XSLT processor running over Java VM. Then, if you have heavy load on it, the mapping runtime will consume the resources necessary to run the xslt processor (which is, by itself, very resource consuming) and also to treat that heavy input.
    Regards,
    Henrique.

  • Catching Mapping error at runtime using a udf

    Hi AlL,
    I read some blog where it was discussed.. we can catch runtime error ? Is it possible?
    how will we be able to catch the runtime error say during the mapping we got an error and we want to catch that error and log it somewhere or throw user defined exception?
    I guess at runtime all the runtime details are stored in SMPPMAP3 table. which is the field which contain the any runtime error?

    Hi,
    you cannot do it using an UDF as a uDF will only work on fields that
    are in the message
    you can throw exceptions from UDF but not catch
    to catch you can use an exception branch of a block stpe in an intgration process BPM
    Regards,
    michal

  • Determine Process ID at runtime via UDF

    Hello to all,
    I need to determine the process id (instance) of the workflow (ccBPM) at runtime within a transformation step (message mapping). Is there a way to access the BPE data via UDF similar to the runtime constants (e.g. MESSAGE_ID, ...)?
    Regards
    Gerhard

    [http://help.sap.com/saphelp_nw2004s/helpdata/en/b3/9a2aeb24dc4ab6b1855c99157529e4/content.htm]

  • PI 7.0 - UDF to access runtime constants

    Hi experts,
    I've created some user-defined functions to use in my Message Mappings. I'm particularly interested in having Message Mappings that allow me to send error e-mails everytime an integration process fails.
    So, in every Message Mapping I've created an UDF with the following code (saw this on SAP Help):
    MappingTrace trace;
    String constant;
    java.util.Map map;
    trace = container.getTrace();
    // get constant map
    map = container.getTransformationParameters();
    constant = (String) map.get(
            StreamTransformationConstants.INTERFACE_NAMESPACE);
    trace.addInfo("INTERFACE_NAMESPACE:" + constant);
    return constant;
    Now, almost everything is working fine. I'm receiving some error e-mails with the correct namespace, but the rest of them comes with a "null" instead of namespace - this is only happening in some Message Mappings - I have MM_A and MM_B of the same interface responsible for sending e-mails on diferent stages of the integration process; The e-mail received from MM_A contains the correct namespace but the other don't (comes with null).
    Can you help me on this?
    Thanks in advance.
    Regards,
    Ricardo Inácio

    PI is available in the options during the install of ECC.

  • Update a UDF field at runtime

    I designed the Sales Order and Sales BOL form in Crystal Reports. I am looking to capture and update an UDF field every time I'm printing the one of those reports in SAP B1 2005 A. The reason for doing this is to display on the report "Original" when printed for the first time, "Duplicate" when printed for the second time and so forth. Is this possible? Thank you.

    You could do a Formatted search on the UDF to change to a value when the Field "Printed" is changed.
    You might want to do "Refresh Regularly" option in Formatted Search.
    Krishnan

  • UDF value addition at runtime

    Hello Experts,
    As there are lots of UDFs are being used in the system. But problem we are facing is that whenever request comes to add a new value in UDF. I need to shutdown the system rather close all the screens and all the users are required to stop working.
    Is there any way that we can add value without interupting the users.
    Thanks

    Hi Muhammad,
    If I understand you correctly, you are trying to add new UDF to B1, right?
    It is very important to ensure nobody else in the system. Because you are making change to your database, not just add a value like normal data entry.
    You can ignore the warning to add or edit UDF even with someone else logged in.  However, that should be avoid since you are taking chance to be lucky that those user are not lock up any tables.
    It is not convient for you. But those restriction will ensure your database integrity.
    My recommendation is: plan ahead for UDF, add them in a batch and restrict adding UDF only when there is no other choice
    Thanks,
    Gordon

  • Issue in RFCLookup UDF

    Hi All,
    Requesting your help in fixing an UDF issue.
    This UDF is to check for a table entry and if not found it will create an alert with some source values.
    Now the problem is, alert mails are getting created but the values are not getting passed.
    Here is the source code:
    AbstractTrace trace;
    trace = container.getTrace();
    MappingTrace trace1;
    trace1 = container.getTrace();
    Object cachedValue = null;
    String result = null;
    String sender = null;
    String receiver = null;
    //Check if source is null or blank. If so then pass blank value to target 
    if(((sourceValue1.trim()).equals("")) ||  ((sourceValue2.trim()).equals("")) || ((sourceValue3.trim()).equals("")))
      result="";
    else
                                 Map map = container.getTransformationParameters();
    //Sender System name which is the same as the Sender Business System name in Integration Directory
    sender = (String) map.get(StreamTransformationConstants.SENDER_SYSTEM);
    //Receiver System name which is the same as the Receiver Business System name in Integration Directory
    receiver = (String) map.get(StreamTransformationConstants.RECEIVER_SYSTEM);
    // Parameter for cache value. A semicolon is used as a separator between keys
    String CONTAINER_PARAMETER = subCat.trim() + UDFReader.getString("PARAMETER_DELIMETER") +sourceValue1.trim() + UDFReader.getString("PARAMETER_DELIMETER") +sourceValue2.trim() + UDFReader.getString("PARAMETER_DELIMETER") +sourceValue3.trim();
    trace1.addWarning("CONTAINER PARAMETER: " + CONTAINER_PARAMETER + "\n");
    trace.addDebugMessage(UDFReader.getString("CACHE_CONTAINER_PARAMETER_TEXT") + CONTAINER_PARAMETER);
    // Retrieve cached value
    cachedValue = container.getParameter(CONTAINER_PARAMETER);
    if(cachedValue!=null)
      // Cached value found
      result = cachedValue.toString();
      trace.addDebugMessage(UDFReader.getString("CACHE_RESULT_TEXT") + result);
    else
      // Cached value not present. Fetch value from database
      // Build key column names array to be passed to java class
      String keyColNames[] =new String[6];
      keyColNames[0]=UDFReader.getString("SAP_SYSTEM_COLUMN_NAME");
      keyColNames[1]=UDFReader.getString("LEGACY_SYSTEM_COLUMN_NAME");
      keyColNames[2]=UDFReader.getString("SUBCATEGORY_COLUMN_NAME");
      keyColNames[3]=sourceField1;
      keyColNames[4]=sourceField2;
      keyColNames[5]=sourceField3;
      trace1.addWarning("KeyColNames" + keyColNames[0] + "\n" + keyColNames[1] + "\n" + keyColNames[2] + "\n" + keyColNames[3] + "\n" + keyColNames[4] + "\n" + keyColNames[5] + "\n");
      // Build key column values array to be passed to java class
      String keyColValues[] = new String[6];
       //Check whether sender system is SAP or Legacy
                             if(sourceField1.startsWith(UDFReader.getString("SAP_SYSTEM_PREFIX")))
       //Sender system is SAP
       keyColValues[0]=sender;
       //Receiver system is Legacy
       keyColValues[1]=receiver;
                             else
       //Receiver system is SAP    
       keyColValues[0]=receiver;
       //Sender system is Legacy
       keyColValues[1]=sender;
      keyColValues[2]=subCat.trim();
      keyColValues[3]=sourceValue1.trim();
      keyColValues[4]=sourceValue2.trim();
      keyColValues[5]=sourceValue3.trim();
      // Fetch result using java class
      result=RfcLookupHandler.RFCLookup(table,keyColNames, 
    keyColValues,targetField,trace);
    trace1.addWarning("Result:" + result);
      if(!result.equals(RfcLookupHandler.VALNOTFOUND))
       // Record found in database
       container.setParameter(CONTAINER_PARAMETER,result);
      else
       // Record not found in database
                                              //Autogenerated message id generated at runtime
       String msgId = (String) map.get ( StreamTransformationConstants.MESSAGE_ID);
       //Dynamic alert message details-Trigerred through RFC SALERT_CREATE
       String element[] = new String[9];
       String tabIndex[] = new String[9];
       String elementLength[] = new String[9];
       String type[] = new String[9];
       String value[] = new String[9];
       //Container names for alert message
       element[0] = UDFReader.getString("CONTAINER_NAME_MESSAGE_ID");
       element[1] =UDFReader.getString("CONTAINER_NAME_INTERFACE_NAME");
       element[2] =UDFReader.getString("CONTAINER_NAME_OBJECT_TYPE");
            //element[2]="SAP_MAT_NO";
       element[3] =UDFReader.getString("CONTAINER_NAME_OBJECT_TYPE"); ;
       element[4] =UDFReader.getString("CONTAINER_NAME_OBJECT_TYPE");
            //element[4]="PLANT";
       element[5] = UDFReader.getString("CONTAINER_NAME_OBJECT_VALUE");
       element[6] = UDFReader.getString("CONTAINER_NAME_OBJECT_VALUE");
       element[7] =UDFReader.getString("CONTAINER_NAME_OBJECT_VALUE");
       element[8] ="TABLE";
       trace1.addWarning("Warning: \n" + element[0]  + "\n" + element[1]  + "\n" + element[2]  + "\n" + element[3]  + "\n" + element[4]  + "\n" + element[5]  + "\n" + element[6]  + "\n" + element[7]  + "\n" + element[8]);
       //Tab index of container variables in alert message
       tabIndex[0] = "000001";
       tabIndex[1] = "000002";
       tabIndex[2] = "000003";
       tabIndex[3] = "000004";  
       tabIndex[4] = "000005";  
       tabIndex[5] = "000006";  
       tabIndex[6] = "000007";  
       tabIndex[7] = "000008";
       tabIndex[8] = "000009";
       //Length of containers
       elementLength[0] = elementLength[1] = elementLength[2] =elementLength[3] = elementLength[4] = elementLength[5] = elementLength[6] =  elementLength[7]=elementLength[8]=UDFReader.getString("CONTAINER_VALUE_LENGTH");
       //Data type of containers
       type[0] = type[1] = type[2]  = type[3] = type[4]=type[5]  = type[6]  =type[7]  ="C";
       //Values supplied to containers
       value[0] =msgId;
       value[1] =interfaceName;
       value[2] =  sourceField1;
       value[3] = UDFReader.getString("MESSAGE_SEPARATOR_HYPHEN") + sourceValue1.trim();
       value[4] = UDFReader.getString("MESSAGE_SEPARATOR_COMMA")  + sourceField2;
       value[5] = UDFReader.getString("MESSAGE_SEPARATOR_HYPHEN") + sourceValue2.trim();
       value[6] = UDFReader.getString("MESSAGE_SEPARATOR_COMMA")  + sourceField3;
       value[7] = UDFReader.getString("MESSAGE_SEPARATOR_HYPHEN") + sourceValue3.trim();
       value[8] =table;
    trace1.addWarning("Table: "+table);
       // Check error handling flag
       if(errorHandlingFlag.equalsIgnoreCase("E"))
       //Throw Error and generate alert message
       trace.addInfo(UDFReader.getString("NO_RESULT_FLAG_E_TRACE"));
    trace1.addWarning("Error Flag: E");
    for (int i=0; i<9; i++){
    trace1.addWarning("Parameters["+i+"]: " +value[i]);
       result = SUPPRESS;
       RfcAlertHandler.RFCAlert(alertCat,element,tabIndex,elementLength,type,value,trace);
       throw new ValueMappingException(UDFReader.getString("NO_RESULT_FLAG_E_EXCEPTION"));
       else if(errorHandlingFlag.equalsIgnoreCase("N"))
        //Pass 'NA' value to target
        result=UDFReader.getString("NO_RESULT_FLAG_N_VALUE_PASSED");
        trace.addInfo(UDFReader.getString("NO_RESULT_FLAG_N_TRACE"));
    trace1.addWarning("Error Flag: N");
       else if(errorHandlingFlag.equalsIgnoreCase("B"))
        //Pass blank value to target
        result="";
        trace.addInfo(UDFReader.getString("NO_RESULT_FLAG_B_TRACE"));
    trace1.addWarning("Error Flag: B");
       else
        //Incorrect Error Handling Flag
        trace.addInfo(UDFReader.getString("INCORRECT_FLAG_TRACE"));
    trace1.addWarning("Error Flag: INCORRECT");
        result = SUPPRESS;
        throw new ValueMappingException(UDFReader.getString("INCORRECT_FLAG_EXCEPTION"));
    return result;
    Can someone check where could be the problem?
    Thanks,
    Glory.

    What is RfcLookupHandler? And where is RFC channel settings?

  • NoClassDefFoundErrr in PI 7.31 PROD-System with UDF

    Hi Gurus,
    I'm facing a weird problem:
    This is my environment: PI 7.31;
    Landscape: Dev --> QA --> PROD
    All UDFs are save in the central SWCV: CentralLibrary.
    All mappings with UDFs in PROD do not work, but in DEV and QA are OK.
    The Error Log in Mapping is here:
    javax.ejb.EJBException: nested exception is: java.lang.RuntimeException: java.lang.NoClassDefFoundError: de/xyzcustomer/CentralLibrary/CL_StringConvert
    at java.lang.ClassLoader.loadClass(ClassLoader.java:308) ... 52 more Caused by: com.sap.aii.ib.core.mapping.execution.ResourceNotFoundException: Unable to find resource de/ xyzcustomer/CentralLibrary/CL_StringConvert in the following software component versions: 26dd6550-707e-11e2-a09d-deb10ad76533, f0c662d0-6f7b-11e2-b498-deb10ad76533 at com.sap.aii.ib.server.mapping.execution.MappingFinderImpl.readClass(MappingFinderImpl.java:81) at com.sap.aii.ibrep.server.mapping.rt.ArchiveClassLoader.findClass(ArchiveClassLoader.java:92)
    I’ve tried the following approaches:
    Reimport central Library and Message-Mapping from DEV into PROD
    Full mapping runtime cache refresh in Administration – Mapping Runtime
    Create a local library in the Mapping namespace. It works well in DEV and QA, but in PROD still gets same error.
    Could anyone help me?!
    Thanks a lot and regards
    Christine

    Hi Jannus,
    i tested this scenario once more and monitored it with xpi_inspector.
    In the runtime there is no mapping error.
    But in Enterprise Services Builder, I test the mapping in test module, i get this NoClassDelFounderror.
    The whole error-log is as below:
    javax.ejb.EJBException: nested exception is: java.lang.RuntimeException:
    java.lang.NoClassDefFoundError: de/xyzcustomer/CentralLibrary/CL_StringConvert
    java.lang.RuntimeException: java.lang.NoClassDefFoundError:
    de/xyzcustomer/CentralLibrary/CL_StringConvert at
    com.sap.engine.services.ejb3.runtime.impl.RequestInvocationContext.proceedFinal
    (RequestInvocationContext.java:99) at
    com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed
    (AbstractInvocationContext.java:166) at
    com.sap.engine.services.ejb3.runtime.impl.Interceptors_StatesTransition.invoke
    (Interceptors_StatesTransition.java:19) at
    com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed
    (AbstractInvocationContext.java:179) at
    com.sap.engine.services.ejb3.runtime.impl.Interceptors_Resource.invoke
    (Interceptors_Resource.java:50) at
    com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed
    (AbstractInvocationContext.java:179) at
    com.sap.engine.services.ejb3.runtime.impl.Interceptors_Transaction.doWorkWithAttribute
    (Interceptors_Transaction.java:37) at
    com.sap.engine.services.ejb3.runtime.impl.Interceptors_Transaction.invoke
    (Interceptors_Transaction.java:21) at
    com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed
    (AbstractInvocationContext.java:179) at
    com.sap.engine.services.ejb3.runtime.impl.Interceptors_MethodRetry.invoke
    (Interceptors_MethodRetry.java:46) at
    com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed
    (AbstractInvocationContext.java:179) at
    com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed
    (AbstractInvocationContext.java:191) at
    com.sap.engine.services.ejb3.runtime.impl.Interceptors_StatelessInstanceGetter.invoke
    (Interceptors_StatelessInstanceGetter.java:23) at
    com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed
    (AbstractInvocationContext.java:179) at
    com.sap.engine.services.ejb3.runtime.impl.Interceptors_SecurityCheck.invoke
    (Interceptors_SecurityCheck.java:25) at
    com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed
    (AbstractInvocationContext.java:179) at
    com.sap.engine.services.ejb3.runtime.impl.Interceptors_ExceptionTracer.invoke
    (Interceptors_ExceptionTracer.java:17) at
    com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed
    (AbstractInvocationContext.java:179) at
    com.sap.engine.services.ejb3.runtime.impl.DefaultInvocationChainsManager.startChain
    (DefaultInvocationChainsManager.java:138) at
    com.sap.engine.services.ejb3.runtime.impl.DefaultEJBProxyInvocationHandler.invoke
    (DefaultEJBProxyInvocationHandler.java:164) at $Proxy787.execute(Unknown Source) at
    sun.reflect.GeneratedMethodAccessor1723.invoke(Unknown Source) at
    sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at
    java.lang.reflect.Method.invoke(Method.java:597) at
    com.sap.engine.services.rmi_p4.P4DynamicSkeleton.dispatch(P4DynamicSkeleton.java:240) at
    com.sap.engine.services.rmi_p4.DispatchImpl._runInternal(DispatchImpl.java:466) at
    com.sap.engine.services.rmi_p4.server.ServerDispatchImpl.run(ServerDispatchImpl.java:69) at
    com.sap.engine.services.rmi_p4.P4Message.process(P4Message.java:72) at
    com.sap.engine.services.rmi_p4.P4Message.execute(P4Message.java:43) at
    com.sap.engine.services.cross.fca.FCAConnectorImpl.executeRequest
    (FCAConnectorImpl.java:999) at com.sap.engine.services.rmi_p4.P4Message.process
    (P4Message.java:59) at com.sap.engine.services.cross.fca.MessageReader.run
    (MessageReader.java:55) at com.sap.engine.core.thread.execution.Executable.run
    (Executable.java:122) at com.sap.engine.core.thread.execution.Executable.run
    (Executable.java:101) at com.sap.engine.core.thread.execution.CentralExecutor
    $SingleThread.run(CentralExecutor.java:328) Caused by: java.lang.NoClassDefFoundError:
    de/xyzcustomer/CentralLibrary/CL_StringConvert at
    com.sap.xi.tf._MM_MT_RequirementPhotoCopy_to_MT_InvoicePhotoCopy_$MT$InnerLibsList.<init>
    (_MM_MT_RequirementPhotoCopy_to_MT_InvoicePhotoCopy_.java:88) at
    com.sap.xi.tf._MM_MT_RequirementPhotoCopy_to_MT_InvoicePhotoCopy_$MT$InnerLibsList.<init>
    (_MM_MT_RequirementPhotoCopy_to_MT_InvoicePhotoCopy_.java:87) at
    com.sap.xi.tf._MM_MT_RequirementPhotoCopy_to_MT_InvoicePhotoCopy_.<init>
    (_MM_MT_RequirementPhotoCopy_to_MT_InvoicePhotoCopy_.java:19) at
    sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at
    sun.reflect.NativeConstructorAccessorImpl.newInstance
    (NativeConstructorAccessorImpl.java:39) at
    sun.reflect.DelegatingConstructorAccessorImpl.newInstance
    (DelegatingConstructorAccessorImpl.java:27) at java.lang.reflect.Constructor.newInstance
    (Constructor.java:513) at java.lang.Class.newInstance0(Class.java:355) at
    java.lang.Class.newInstance(Class.java:308) at
    com.sap.aii.ibrep.server.mapping.exec.ExecuteXiMappingCommand.transformInternal
    (ExecuteXiMappingCommand.java:180) at
    com.sap.aii.ibrep.server.mapping.exec.ExecuteXiMappingCommand.execute
    (ExecuteXiMappingCommand.java:95) at
    com.sap.aii.ib.server.mapping.exec.CommandManager.execute(CommandManager.java:43) at
    com.sap.aii.ibrep.server.mapping.ServerMapService.execute(ServerMapService.java:40) at
    com.sap.aii.ibrep.server.mapping.MapServiceBean.execute(MapServiceBean.java:40) at
    sun.reflect.GeneratedMethodAccessor1724.invoke(Unknown Source) at
    sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at
    java.lang.reflect.Method.invoke(Method.java:597) at
    com.sap.engine.services.ejb3.runtime.impl.RequestInvocationContext.proceedFinal
    (RequestInvocationContext.java:47) ... 34 more Caused by: java.lang.ClassNotFoundException:
    Class de.xyzcustomer.CentralLibrary.CL_StringConvert not found at
    com.sap.aii.ibrep.server.mapping.rt.ArchiveClassLoader.findClass
    (ArchiveClassLoader.java:110) at java.lang.ClassLoader.loadClass(ClassLoader.java:367) at
    java.lang.ClassLoader.loadClass(ClassLoader.java:308) ... 52 more Caused by:
    com.sap.aii.ib.core.mapping.execution.ResourceNotFoundException: Unable to find resource
    de/xyzcustomer/CentralLibrary/CL_StringConvert.class in the following software component
    versions: 26dd6550-707e-11e2-a09d-deb10ad76533, f0c662d0-6f7b-11e2-b498-deb10ad76533 at
    com.sap.aii.ib.server.mapping.execution.MappingFinderImpl.readClass
    (MappingFinderImpl.java:81) at
    com.sap.aii.ibrep.server.mapping.rt.ArchiveClassLoader.findClass
    (ArchiveClassLoader.java:92) ... 54 more javax.ejb.EJBException: nested exception is:
    java.lang.RuntimeException: java.lang.NoClassDefFoundError:
    de/xyzcustomer/CentralLibrary/CL_StringConvert at
    com.sap.engine.services.ejb3.runtime.impl.RequestInvocationContext.proceedFinal
    (RequestInvocationContext.java:99) at
    com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed
    (AbstractInvocationContext.java:166) at
    com.sap.engine.services.ejb3.runtime.impl.Interceptors_StatesTransition.invoke
    (Interceptors_StatesTransition.java:19) at
    com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed
    (AbstractInvocationContext.java:179) at
    com.sap.engine.services.ejb3.runtime.impl.Interceptors_Resource.invoke
    (Interceptors_Resource.java:50) at
    com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed
    (AbstractInvocationContext.java:179) at
    com.sap.engine.services.ejb3.runtime.impl.Interceptors_Transaction.doWorkWithAttribute
    (Interceptors_Transaction.java:37) at
    com.sap.engine.services.ejb3.runtime.impl.Interceptors_Transaction.invoke
    (Interceptors_Transaction.java:21) at
    com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed
    (AbstractInvocationContext.java:179) at
    com.sap.engine.services.ejb3.runtime.impl.Interceptors_MethodRetry.invoke
    (Interceptors_MethodRetry.java:46) at
    com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed
    (AbstractInvocationContext.java:179) at
    com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed
    (AbstractInvocationContext.java:191) at
    com.sap.engine.services.ejb3.runtime.impl.Interceptors_StatelessInstanceGetter.invoke
    (Interceptors_StatelessInstanceGetter.java:23) at
    com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed
    (AbstractInvocationContext.java:179) at
    com.sap.engine.services.ejb3.runtime.impl.Interceptors_SecurityCheck.invoke
    (Interceptors_SecurityCheck.java:25) at
    com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed
    (AbstractInvocationContext.java:179) at
    com.sap.engine.services.ejb3.runtime.impl.Interceptors_ExceptionTracer.invoke
    (Interceptors_ExceptionTracer.java:17) at
    com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed
    (AbstractInvocationContext.java:179) at
    com.sap.engine.services.ejb3.runtime.impl.DefaultInvocationChainsManager.startChain
    (DefaultInvocationChainsManager.java:138) at
    com.sap.engine.services.ejb3.runtime.impl.DefaultEJBProxyInvocationHandler.invoke
    (DefaultEJBProxyInvocationHandler.java:164) at $Proxy787.execute(Unknown Source) at
    sun.reflect.GeneratedMethodAccessor1723.invoke(Unknown Source) at
    sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at
    java.lang.reflect.Method.invoke(Method.java:597) at
    com.sap.engine.services.rmi_p4.P4DynamicSkeleton.dispatch(P4DynamicSkeleton.java:240) at
    com.sap.engine.services.rmi_p4.DispatchImpl._runInternal(DispatchImpl.java:466) at
    com.sap.engine.services.rmi_p4.server.ServerDispatchImpl.run(ServerDispatchImpl.java:69) at
    com.sap.engine.services.rmi_p4.P4Message.process(P4Message.java:72) at
    com.sap.engine.services.rmi_p4.P4Message.execute(P4Message.java:43) at
    com.sap.engine.services.cross.fca.FCAConnectorImpl.executeRequest
    (FCAConnectorImpl.java:999) at com.sap.engine.services.rmi_p4.P4Message.process
    (P4Message.java:59) at com.sap.engine.services.cross.fca.MessageReader.run
    (MessageReader.java:55) at com.sap.engine.core.thread.execution.Executable.run
    (Executable.java:122) at com.sap.engine.core.thread.execution.Executable.run
    (Executable.java:101) at com.sap.engine.core.thread.execution.CentralExecutor
    $SingleThread.run(CentralExecutor.java:328) Caused by: java.lang.RuntimeException:
    java.lang.NoClassDefFoundError: de/xyzcustomer/CentralLibrary/CL_StringConvert ... 35 more
    Caused by: java.lang.NoClassDefFoundError: de/xyzcustomer/CentralLibrary/CL_StringConvert
    at com.sap.xi.tf._MM_MT_RequirementPhotoCopy_to_MT_InvoicePhotoCopy_$MT
    $InnerLibsList.<init>(_MM_MT_RequirementPhotoCopy_to_MT_InvoicePhotoCopy_.java:88) at
    com.sap.xi.tf._MM_MT_RequirementPhotoCopy_to_MT_InvoicePhotoCopy_$MT$InnerLibsList.<init>
    (_MM_MT_RequirementPhotoCopy_to_MT_InvoicePhotoCopy_.java:87) at
    com.sap.xi.tf._MM_MT_RequirementPhotoCopy_to_MT_InvoicePhotoCopy_.<init>
    (_MM_MT_RequirementPhotoCopy_to_MT_InvoicePhotoCopy_.java:19) at
    sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at
    sun.reflect.NativeConstructorAccessorImpl.newInstance
    (NativeConstructorAccessorImpl.java:39) at
    sun.reflect.DelegatingConstructorAccessorImpl.newInstance
    (DelegatingConstructorAccessorImpl.java:27) at java.lang.reflect.Constructor.newInstance
    (Constructor.java:513) at java.lang.Class.newInstance0(Class.java:355) at
    java.lang.Class.newInstance(Class.java:308) at
    com.sap.aii.ibrep.server.mapping.exec.ExecuteXiMappingCommand.transformInternal
    (ExecuteXiMappingCommand.java:180) at
    com.sap.aii.ibrep.server.mapping.exec.ExecuteXiMappingCommand.execute
    (ExecuteXiMappingCommand.java:95) at
    com.sap.aii.ib.server.mapping.exec.CommandManager.execute(CommandManager.java:43) at
    com.sap.aii.ibrep.server.mapping.ServerMapService.execute(ServerMapService.java:40) at
    com.sap.aii.ibrep.server.mapping.MapServiceBean.execute(MapServiceBean.java:40) at
    sun.reflect.GeneratedMethodAccessor1724.invoke(Unknown Source) at
    sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at
    java.lang.reflect.Method.invoke(Method.java:597) at
    com.sap.engine.services.ejb3.runtime.impl.RequestInvocationContext.proceedFinal
    (RequestInvocationContext.java:47) ... 34 more Caused by: java.lang.ClassNotFoundException:
    Class de.xyzcustomer.CentralLibrary.CL_StringConvert not found at
    com.sap.aii.ibrep.server.mapping.rt.ArchiveClassLoader.findClass
    (ArchiveClassLoader.java:110) at java.lang.ClassLoader.loadClass(ClassLoader.java:367) at
    java.lang.ClassLoader.loadClass(ClassLoader.java:308) ... 52 more Caused by:
    com.sap.aii.ib.core.mapping.execution.ResourceNotFoundException: Unable to find resource
    de/xyzcustomer/CentralLibrary/CL_StringConvert.class in the following software component
    versions: 26dd6550-707e-11e2-a09d-deb10ad76533, f0c662d0-6f7b-11e2-b498-deb10ad76533 at
    com.sap.aii.ib.server.mapping.execution.MappingFinderImpl.readClass
    (MappingFinderImpl.java:81) at
    com.sap.aii.ibrep.server.mapping.rt.ArchiveClassLoader.findClass
    (ArchiveClassLoader.java:92) ... 54 more  See error logs for details

  • Exception on read or set UDF document lines value

    Hi All,
    have a big problem...
    I'm creating invoice documents from many and many delivery documents via DI API.
    In some cases, my addon gives an exception reading or setting UDF line fields.
    Here is the exception message:
    System.Runtime.InteropServices.COMException (0x80010105): The server has rise an exception. (Eccezione da HRESULT: 0x80010105(RPC_E_SERVERFAULT))
    in SAPbobsCOM.FieldClass.get_Value() in Morato.CreaDocFatturazioneMassiva.CopyUDFLineFields(String)
    or
    System.Runtime.InteropServices.COMException (0x80010105): The server has rise an exception. (Eccezione da HRESULT: 0x80010105(RPC_E_SERVERFAULT))
    in SAPbobsCOM.FieldClass.set_Value() in Morato.CreaDocFatturazioneMassiva.CopyUDFLineFields(String)
    The strange thing is that if I create an invoices from a little quantity of deliveries, there is no problem. The error seems to rise when I create an invoice from a huge quantity of deliveries.
    The code is:
    Private Function CopyUDFLineFields(ByVal oLineNum As String) As Boolean
            Dim i As Integer
            oDocFrom.Lines.SetCurrentLine(oLineNum)
            Try
                With oDocFrom.Lines.UserFields
                    For i = 0 To .Fields.Count - 1
                        Select Case .Fields.Item(i).Type
                            Case SAPbobsCOM.BoFieldTypes.db_Date
                                '// campi di tipo data
                                Select Case .Fields.Item(i).SubType
                                    Case SAPbobsCOM.BoFldSubTypes.st_Time
                                        '// campi di tipo ora
                                        If Hour(.Fields.Item(i).Value) <> "0" Or Minute(.Fields.Item(i).Value) <> "0" Then
                                            oDocTo.Lines.UserFields.Fields.Item(i).Value = .Fields.Item(i).Value
                                        End If
                                    Case Else
                                        If Year(oDocFrom.Lines.UserFields.Fields.Item(i).Value) <> "1899" And Year(.Fields.Item(i).Value) <> "1999" Then
                                            oDocTo.Lines.UserFields.Fields.Item(i).Value = .Fields.Item(i).Value
                                        End If
                                End Select
                            Case SAPbobsCOM.BoFieldTypes.db_Float
                                '// campi di tipo unità e totale
                                If .Fields.Item(i).SubType = SAPbobsCOM.BoFldSubTypes.st_Measurement Or .Fields.Item(i).SubType = SAPbobsCOM.BoFldSubTypes.st_Percentage Or .Fields.Item(i).SubType = SAPbobsCOM.BoFldSubTypes.st_Price Or .Fields.Item(i).SubType = SAPbobsCOM.BoFldSubTypes.st_Quantity Then
                                    oDocTo.Lines.UserFields.Fields.Item(i).Value = CDbl(.Fields.Item(i).Value)
                                End If
                            Case SAPbobsCOM.BoFieldTypes.db_Alpha
                                '// campi di tipo stringa
                                If Not String.IsNullOrEmpty(oDocFrom.Lines.UserFields.Fields.Item(i).Value) Then
                                    oDocTo.Lines.UserFields.Fields.Item(i).Value = .Fields.Item(i).Value.ToString
                                End If
                            Case SAPbobsCOM.BoFieldTypes.db_Numeric
                                oDocTo.Lines.UserFields.Fields.Item(i).Value = Val(.Fields.Item(i).Value)
                            Case SAPbobsCOM.BoFieldTypes.db_Memo
                                oDocTo.Lines.UserFields.Fields.Item(i).Value = .Fields.Item(i).Value.ToString
                            Case Else
                                '// altri tipi stringa
                                If Not String.IsNullOrEmpty(oDocFrom.Lines.UserFields.Fields.Item(i).Value) Then
                                    oDocTo.Lines.UserFields.Fields.Item(i).Value = .Fields.Item(i).Value.ToString
                                End If
                        End Select
                    Next i
                End With
                Return True
            Catch ex As Exception
                SBO_Application.MessageBox(ex.ToString & " - " & oDocFrom.Lines.UserFields.Fields.Item(i).Name.ToString)
                Return False
            End Try
        End Function
    Anyone have experienced something similar?
    Kind Regards,
    Paolo Caricasole.
    Edited by: Rui Pereira on Dec 23, 2008 4:26 PM

    Please refer to note#1235603
    SAP Notes: [http://service.sap.com/notes|http://service.sap.com/notes]
    Replace:
    oDocTo.Lines.UserFields.Fields.Item(i).Value
    with:
    Document_Lines oLines = oDocTo.Lines
    oLines.UserFields.Fields.Item(i).Value
    Regards, Yatsea

  • Same filename from a sender to receiver :: DO we really need UDF ?

    Hi
    This is in refrence of Weblog " <i>same filename from a sender to a receiver file adapter "</i> by <i>Michal Krawczyk</i>.
    /people/michal.krawczyk2/blog/2005/11/10/xi-the-same-filename-from-a-sender-to-a-receiver-file-adapter--sp14
    Actually I worked on another weblog by " <i>Shabarish Vijayakumar</i> "-->
    /people/shabarish.vijayakumar/blog/2006/04/03/xi-in-the-role-of-a-ftp
    And I am getting file created on the receiver side with the same file name as on the sender side without using the user-defined function mentioned in Michal's weblog.
    Now my question do we really need UDF for same file name when on the sender we are polling for one file only by its name.
    I am not exaclty getting the benefit of this feature. Can you tell me why do we need this feature as in whatever scenarios I worked I mentioned the file names in both Sender & Receiver File Adapters.
    So I am not getting what is the use of using this UDF, when we mention the name of file needs to be created on Receiver side.
    - Lalit Chaudhary -

    Hi
    I put this code for UDF -->
    <i>String valueNew;
    DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    DynamicConfigurationKey key = DynamicConfigurationKey.create("http://sap.com/xi/XI/System/File","FileName");
    String valueOld = conf.get(key);
    if (valueOld != null)
        valueNew = valueOld.replaceAll("input123",name);
        conf.put(key, valueNew);
    return valueNew;</i>
    Signature of UDF is this :: <u>public String GetFileName(String name,Container container)</u>
    But when I am testing this UDF, I am getting following RunTime exception -->
    <i>Runtime exception during processing target field mapping /ns0:FileFTP_InOut_MT/File_nm. The message is: Exception:[java.lang.NullPointerException] in class com.sap.xi.tf._FileFTP_MsgMapping_UDF_ method GetFileName$[lalit, com.sap.aii.mappingtool.tf3.rt.Context@735df3b0] com.sap.aii.mappingtool.tf3.MessageMappingException: Runtime exception during processing target field mapping /ns0:FileFTP_InOut_MT/File_nm. The message is: Exception:[java.lang.NullPointerException] in class com.sap.xi.tf._FileFTP_MsgMapping_UDF_ method GetFileName$[lalit, com.sap.aii.mappingtool.tf3.rt.Context@735df3b0]</i>
    I am not much of Java Guy, can you pls. suggest what am I doing wrong, I copied this code from <a href="http://help.sap.com/saphelp_nw04/helpdata/en/43/03612cdecc6e76e10000000a422035/content.htm">SAP Help</a>
    - Lalit -

  • Dynamic Attributes with UDF - NullPointerException

    Hello,
    I want to set the file name of an file receiver by means of setting dynamic attributes in an UDF.
    I use the following code and map the output to the root node of the target message (one input variable is var1)
    DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    DynamicConfigurationKey key = DynamicConfigurationKey.create("http://sap.com/xi/XI/System/File","FileName");
    String myFileName = var1;
    conf.put(key, myFileName);
    return "";
    When I want to test the mapping using the test tab I get a null pointer exception:
    Exception:[java.lang.NullPointerException] in class com.sap.xi.tf
    Could the reason be, that setting dynamic attributes does not work when testing a mapping as the mapping has to be called by the IE runtime or is there any other reason?

    Hi Florain,
    I can understand, but that is how it is designed because the filename paramter can be picked up only during the runtime. But if you use other parameters like interface, sender name etc you can test it in mapping. Please go to test tab and click on parameters  tab. There you see few parameters for runtime also. You can put some value there and then you can test the mapping and you will not receive that error. You dont have filename there, so thats the reason why you are getting error. Hope in next release SAP would come up with this option.
    Regards,
    ---Satish

  • Error in mappingwith dynamic configuration using udf

    Hi All,
    Good Morning,
    i am working with ABAP proxy to file scenarion but here according my client requirement i am using udf for file dynamic configuration.
    In mapping, i mapped the field from "Filename" to message type tag(receiver file header)  "/ns0:MTxxxxxxDataFile". between there two fields i am using the following udf for dynamic configuration. but i got error after testing with test data in mapping that is also mentioned below.
    plz help me to solve the error. i will be wait for ur immediate response this sis very urgent.
    very thankfull to immediate response.
    UDF:
    i am not puting any packages here.
    public String putFileNameInHeader1(String a,Container container){
    //write your code here
    DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    DynamicConfigurationKey key = DynamicConfigurationKey.create("http://sap.com/xi/XI/System/File", "FileName");
    conf.put(key, a);
    return "";
    ERROR:
    12:21:30 Start of test
    Compilation of MMSAPLegacySalesDataToCOGNOS successful Runtime exception during processing target field mapping /ns0:MTCOGNOSLegacySalesDataFile. The message is: Exception:[java.lang.NullPointerException] in class com.sap.xi.tf._MMSAPLegacySalesDataToCOGNOS_ method putFileNameInHeader1$[cd00000038, com.sap.aii.mappingtool.tf3.rt.Context@f300f30] com.sap.aii.mappingtool.tf3.MessageMappingException: Runtime exception during processing target field mapping /ns0:MTCOGNOSLegacySalesDataFile. The message is: Exception:[java.lang.NullPointerException] in class com.sap.xi.tf._MMSAPLegacySalesDataToCOGNOS_ method putFileNameInHeader1$[cd00000038, com.sap.aii.mappingtool.tf3.rt.Context@f300f30] at com.sap.aii.mappingtool.tf3.AMappingProgram.processNode(AMappingProgram.java:350) at com.sap.aii.mappingtool.tf3.AMappingProgram.start(AMappingProgram.java:401) at com.sap.aii.mappingtool.tf3.Transformer.start(Transformer.java:142) at com.sap.aii.mappingtool.tf3.AMappingProgram.execute(AMappingProgram.java:105) at com.sap.aii.ibrep.server.mapping.ServerMapService.transformInternal(ServerMapService.java:431) at com.sap.aii.ibrep.server.mapping.ServerMapService.execute(ServerMapService.java:169) at com.sap.aii.ibrep.sbeans.mapping.MapServiceBean.execute(MapServiceBean.java:52) at com.sap.aii.ibrep.sbeans.mapping.MapServiceRemoteObjectImpl0_0.execute(MapServiceRemoteObjectImpl0_0.java:301) at com.sap.aii.ibrep.sbeans.mapping.MapServiceRemoteObjectImpl0_0p4_Skel.dispatch(MapServiceRemoteObjectImpl0_0p4_Skel.java:146) at com.sap.engine.services.rmi_p4.DispatchImpl._runInternal(DispatchImpl.java:313) at com.sap.engine.services.rmi_p4.DispatchImpl._run(DispatchImpl.java:199) at com.sap.engine.services.rmi_p4.server.P4SessionProcessor.request(P4SessionProcessor.java:136) at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:33) at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRunner.java:41) at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37) at java.security.AccessController.doPrivileged(AccessController.java:215) at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:100) at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:170) Root Cause: com.sap.aii.utilxi.misc.api.BaseRuntimeException: Exception:[java.lang.NullPointerException] in class com.sap.xi.tf._MMSAPLegacySalesDataToCOGNOS_ method putFileNameInHeader1$[cd00000038, com.sap.aii.mappingtool.tf3.rt.Context@f300f30] at com.sap.aii.mappingtool.tf3.rt.FunctionWrapper.calculateCurrentValue(FunctionWrapper.java:83) at com.sap.aii.mappingtool.tf3.rt.FunctionWrapper.cacheValue(FunctionWrapper.java:59) at com.sap.aii.mappingtool.tf3.rt.FunctionWrapper.gotoNextContext(FunctionWrapper.java:37) at com.sap.aii.mappingtool.tf3.AMappingProgram.processNode(AMappingProgram.java:252) at com.sap.aii.mappingtool.tf3.AMappingProgram.start(AMappingProgram.java:401) at com.sap.aii.mappingtool.tf3.Transformer.start(Transformer.java:142) at com.sap.aii.mappingtool.tf3.AMappingProgram.execute(AMappingProgram.java:105) at com.sap.aii.ibrep.server.mapping.ServerMapService.transformInternal(ServerMapService.java:431) at com.sap.aii.ibrep.server.mapping.ServerMapService.execute(ServerMapService.java:169) at com.sap.aii.ibrep.sbeans.mapping.MapServiceBean.execute(MapServiceBean.java:52) at com.sap.aii.ibrep.sbeans.mapping.MapServiceRemoteObjectImpl0_0.execute(MapServiceRemoteObjectImpl0_0.java:301) at com.sap.aii.ibrep.sbeans.mapping.MapServiceRemoteObjectImpl0_0p4_Skel.dispatch(MapServiceRemoteObjectImpl0_0p4_Skel.java:146) at com.sap.engine.services.rmi_p4.DispatchImpl._runInternal(DispatchImpl.java:313) at com.sap.engine.services.rmi_p4.DispatchImpl._run(DispatchImpl.java:199) at com.sap.engine.services.rmi_p4.server.P4SessionProcessor.request(P4SessionProcessor.java:136) at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:33) at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRunner.java:41) at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37) at java.security.AccessController.doPrivileged(AccessController.java:215) at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:100) at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:170) Root Cause: java.lang.reflect.InvocationTargetException at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:85) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:58) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:60) at java.lang.reflect.Method.invoke(Method.java:391) at com.sap.aii.mappingtool.tf3.rt.FunctionWrapper.calculateCurrentValue(FunctionWrapper.java:75) at com.sap.aii.mappingtool.tf3.rt.FunctionWrapper.cacheValue(FunctionWrapper.java:59) at com.sap.aii.mappingtool.tf3.rt.FunctionWrapper.gotoNextContext(FunctionWrapper.java:37) at com.sap.aii.mappingtool.tf3.AMappingProgram.processNode(AMappingProgram.java:252) at com.sap.aii.mappingtool.tf3.AMappingProgram.start(AMappingProgram.java:401) at com.sap.aii.mappingtool.tf3.Transformer.start(Transformer.java:142) at com.sap.aii.mappingtool.tf3.AMappingProgram.execute(AMappingProgram.java:105) at com.sap.aii.ibrep.server.mapping.ServerMapService.transformInternal(ServerMapService.java:431) at com.sap.aii.ibrep.server.mapping.ServerMapService.execute(ServerMapService.java:169) at com.sap.aii.ibrep.sbeans.mapping.MapServiceBean.execute(MapServiceBean.java:52) at com.sap.aii.ibrep.sbeans.mapping.MapServiceRemoteObjectImpl0_0.execute(MapServiceRemoteObjectImpl0_0.java:301) at com.sap.aii.ibrep.sbeans.mapping.MapServiceRemoteObjectImpl0_0p4_Skel.dispatch(MapServiceRemoteObjectImpl0_0p4_Skel.java:146) at com.sap.engine.services.rmi_p4.DispatchImpl._runInternal(DispatchImpl.java:313) at com.sap.engine.services.rmi_p4.DispatchImpl._run(DispatchImpl.java:199) at com.sap.engine.services.rmi_p4.server.P4SessionProcessor.request(P4SessionProcessor.java:136) at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:33) at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRunner.java:41) at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37) at java.security.AccessController.doPrivileged(AccessController.java:215) at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:100) at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:170) Caused by: java.lang.NullPointerException at com.sap.xi.tf._MMSAPLegacySalesDataToCOGNOS_.putFileNameInHeader1$(_MMSAPLegacySalesDataToCOGNOS_.java:853) ... 26 more RuntimeException in Message-Mapping transformation: Runtime exception during processing target field mapping /ns0:MTCOGNOSLegacySalesDataFile. The message is: Exception:[java.lang.NullPointerException] in class com.sap.xi.tf._MMSAPLegacySalesDataToCOGNOS_ method putFileNameInHeader1$[cd00000038, com.sap.aii.mappingtool.tf3.rt.Context@f300f30]
    12:21:35 End of test

    Hi Sai,
    First of all, this UDF is pretty well knaown so there is no error in this UDF or your configuration for this UDF. I can suggest you something that at the time of configuration in IR, give a context object for that particular field of that file and then use the contect object name everywhere to refer that field. and also check the message type config for correction for my sake.
    There is also a possibility that of the input data. i guess you are sending the input file from Cognos and you making the file and putting some where in XI directory and want these to process something and generate with some new desired filename. Check the input because i guess its finding NOTHINg as an Input. check once again.
    Hope this will help you.
    Regards
    Aashish Sinha
    PS : Reward points if helpful.

  • UDF to read a file name and use some of its contents to map fields in target.

    I have a scenario where I need to take the month and year from the file name and map it to suitable fields in the target. Ex - filename_apr2014 from this i should be able to read the month and year and map it. How to do this? I tried the udf -
    public String getFileName(Container container){
    DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    DynamicConfigurationKey key = DynamicConfigurationKey.create("http://sap.com/xi/XI/System/File","FileName");
    String ourSourceFileName = conf.get(key);
    return ourSourceFileName;
    got this error while testing the mapping -
    Runtime exception when processing target-field mapping /ns0:MT_<<>>_Output/I<<>>; root message: Exception:[java.lang.NullPointerException: while trying to invoke the method com.sap.aii.mapping.api.DynamicConfiguration.get(com.sap.aii.mapping.api.DynamicConfigurationKey) of a null object loaded from a local variable at slot 2] in class <<>> method getSourceFileName[com.sap.aii.mappingtool.tf7.rt.Context@5b04fc0f]
    See error logs for details  

    Hi Satish - You declared "conf" twice.
    DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    UDF -
    String filename    = "";
    DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    DynamicConfigurationKey key = DynamicConfigurationKey.create( "http:/"+"/sap.com/xi/XI/System/File","FileName");
    filename = conf.get(key);
    return filename;
    And did you define the variable slot 2 in any of your UDF's?
    The above UDF return the filename and you should handle the sub string later..

Maybe you are looking for

  • Power Saver 7 on Tecra 9000

    Hi everybody, I realized that newer versions of Toshibas Power Saver are available for newer Tecra Notebooks. I am using Power Saver 4 on my Tecra 9000. I just tried to install the latest version of PowerSaver on my Tecra 9000. The installation seeme

  • ANN: ANN: XDK 10.1.0.2.0 for HP-UX64, AIX and LINUX Production Release

    XDK 10.1.0.2.0 production for HP-UX64, AIX and LINUX is ready to download on OTN: http://otn.oracle.com/tech/xml/xdk/software/production10g/index.html

  • My apps won't open on my iPad3

    I tried syncing my laptop and my iPad.  Now none of the apps I purchased will open (like facebook, itunesu, ibooks).  I tried turning it off and on again and tried resetting by holding the sleep and home buttos for 10 seconds.  What do I do now?

  • Crack in screen (late 2008 MacBook Pro)

    Hello everyone, I have searched the 'net and this forum about cracked screens, and have found a lot of useful information, but wanted to post this and ask a few questions anyway, as I haven't found exactly what I am looking for. My late 2008 MacBook

  • FF67-Manual Bank Reconciliation....question regarding automatic clearing

    Hi Dear experts, I have a question regarding manual bank reconciliation, everything is working fine as far as FF67 is concerned but I am having a problem with auto clearing for cheques received in, I know that an algorithm decides which field should