Message mapping -How to change 1.2345 to 12345

Hi everybody,
How can I have all the digits of the source field in the target field with the decimal pont removed.
Source field --1.2345
target field --12345
thanks,
Ramya Shenoy

Hi,
   Prepare an udf to remove decimal point.
  you can use the following java code for udf .
       String s1="";
              for( int i=0; i<a.length();i++)
                   if (a.charAt(i) == '.')  {}
                      else
                       s1= s1 +a.charAt(i);
             return s1;
regards
mahesh

Similar Messages

  • Message mapping with signature changed

    Hello,
    I have a mapping whose incoming and outgoing message has the same message type, let's say the message type for both in and out message is *MT_Material *. The mapping basically copy all data from in message to out message, however, the out message is only created based on certain condition. Therefore I changed the signature to define the Occurance of the out message as 0..1 while the in message has occurance of 1.
    Things work fine, out message only contains data when the condition is fullfilled. However the mapping program expects incoming message like;
    <?xml version="1.0" encoding="UTF-8"?>
    <ns0:Messages xmlns:ns0="http://sap.com/xi/XI/SplitAndMerge">
       <ns0:Message1>
          <ns1:MT_Material xmlns:ns1="http://mynamespace">
             <MatNo>123345</MatNo>
             <MatText>
                <Language>en</Language>
                <Text>esx</Text>
             </MatText>
             <MatText>
                <Language>fr</Language>
                <Text>esxfr</Text>
             </MatText>
          </ns1:MT_Material>
       </ns0:Message1>
    </ns0:Messages>
    Note the xml tags in bold are needed because of the signature change (occurance change). However the outbound interface is based on the message type of MT_Material, thus the sender will NOT send the xml tags in bold, rather following message is sent:
    <?xml version="1.0" encoding="UTF-8"?>
          <ns0:MT_Material xmlns:ns1="http://mynamespace">
             <MatNo>123345</MatNo>
             <MatText>
                <Language>en</Language>
                <Text>esx</Text>
             </MatText>
             <MatText>
                <Language>fr</Language>
                <Text>esxfr</Text>
             </MatText>
          </ns0:MT_Material>
    Message in this format is NOT expected by the mapping program with changed signature, thus mapping is does NOT result in the right result.
    So what should I do with it? looks like change signature doesn't make any sense because it expects different outbound message format as the one without signature changed.
    Basically mapping is PI internal stuff, the sender should not be aware of it, thus sender should just send a message based on the message interface which is based on MT_Material.
    what do you thnk of this?
    Any

    Hi Jayson
    You are correct to some extent we should not force the vendor to send a tag to satisfy middleware. But if the tag is required for the business process what can be done other than forcing as a rule to vendor
    As PI is a XML based tool where XML is tied to a XSD all messages need to follow XSD. Now in your requirement we need to meet the condition for generating the output. Being a middle ware PI is not meant for holding the messages or used as an end point for some communication. It works on two engines and we need to pass IS without error. Mapping will work at IS and if it failed its an error but we have to satisfy condition.
    I have faced similar requirement to yours. I had routed the messages through email to vendor when no output need to be generated as they were incorrect and doesn't follow business rule of the process.
    We can check with Xpath or either some the way we discussed above in case condition is not met
    Thanks
    Gaurav

  • JS confrim popup message box - How to change it into yes or no button?

    confirm popup message box is always with OK or Cancel Button?
    How to change it into Yes or No Button?
    Thank you.

    I don't think you can change those buttons. However you may try use some rich Javascript library like YUI (Yahoo! User Interface) to pop up custom alert and confirm boxes.
    See [http://developer.yahoo.com/yui/examples/container/simpledialog-quickstart.html]
    Cheers,
    Hari

  • Message Mapping: How mapping is handled in ABAP & JAVA STACK

    Hi All,
    I am interested in knowing how the mapping is hanlded in Background. Is that in ABAP or JAVA Stack.
    Whats the architecture behind it?
    Any documents related to it.
    Thanks in Advance.
    Best Regards,
    Yaseen M

    depends on the mapping technology:
    i. Message, Java & XSLT (under Imported Archives) mappings are executed at Java stack;
    ii. ABAP & XSLT (in ABAP stack) mappings are executed at ABAP stack.
    The Integration Engine that processes the message pipeline (which runs in ABAP stack) will either execute a JCo call (using RFC Dest AI_RUNTIME_JCOSERVER) to the Java Stack to execute the mapping or, in the 2nd case, execute the mapping ABAP function directly.
    Regards,
    Henrique.

  • Message Mapping :  How to  appned the  ub occ under UB  occ: Very  urgent

    Hi  SDNers
    My SOurce  str  is  like  this                Traget Str
    Node
      subnode1             1..1              Tstr1 1..1
      subnode2             1..1                 TSr2   1..1
         subnode3          1..ub                Tstr3 1..ub
             subnode4      1..1                      Tstr4   1..1
              subnode5     1..ub                    Tstr5    1..1
                subnode6   1..ub                    Tstr6    1..ub
    now  the  situstaion is
             subnode4      1..1                               Tstr4   1..1
              subnode5     1..ub                              Tstr5    1..1
                subnode6   1..ub -
    Mapped  -
         Tstr6    1..ub
    suppose
            Subonde5  occures  2  times  with  3 and  4  occurence of  subnode6  then
       i  need  to  create  7  Line  for Tstr6
    for  example
        subnode4
              subnode5
                     subnode6----
                     subnode6----
                     subnode6----
        subnode4        
              subnode5
                     subnode6----
                     subnode6----
                     subnode6----
                     subnode6----
    now  i  need  create  the   3+4  =  7  ocurence    i  mean  i  have  to  merge these all  occurence  and  have  to  map  Tstr6
    Thax  a lot  in  advance
    Regards
    Kuldeep

    Kuldeep,
    The structure is lil bit confusing, I f you could populate some data and give us the source and target structure as u needed it will be more helpful.
    Best regards,
    raj.

  • Message Mapping: How to print or export?

    As subject, doesnt seem to be a way to do this.  Have had a look in XSLT_TOOL but doesnt seem to be much help.
    Thanks in advance.

    Thanks guys, getting a little closer...
    Unfortunately, although the tools option allows to export an individual map's metadata, it's not in a usable format for documentation as it contains a lot of irrelevant info (screen layout etc) and is just one map at a time, which is a long way from being able to export an entire mapping to XSLT (or image/printer) in one hit.  The text preview suffers from being per-map and is yet another non-standard format.
    I'm getting the feeling that I'm stuck with Excel spreadsheets!
    Cheers

  • Missing closing tag in message mapping

    Hi experts,
    I have an RFC --> PI --> JDBC scenario with the following message mapping:
    SOURCE --> TRIM --> mapWithDefault [] --> DESTINATION
    If the source field doesn't come, the input XML is a follows:
    <SOURCE/>
    And after the mapping I obtain the following: <DESTINATION></DESTINATION> that is exactly what the reciever system is expecting. This was been working fine until the upgrade to ECC 6.0 of the Sender system. Actually I don't know if it has anything to do, because the RFC XML looks exactly the same, but the user claims it has stopped working since the upgrade.
    Now the same mapping, with the same <SOURCE/> input creates this output: <DESTINATION/>. This is not accepted by the reciver system and throws an error.
    What can be happening? The message mapping has not changed and the RFC XML looks exactly the same....any ideas?? Thanks! Pablo

    >
    Stefan Grube wrote:
    > >. This is not accepted by the reciver system and throws an error.
    > What is the error?
    > If you use JBDC adapter, it is no difference, whetehr you have <tag></tag> or <tag />, because this is the same.
    If  you see the payload in Internet Explorer, for example you'll see <tag />. But if you see the XML with a text editor, it should be <tag></tag>: Before this issue the receiver system was getting a "blank" value, now it's getting "null" and it can't handle it.
    Sarvesh: thanks for your advice but I'm already using that function...
    I'll try Pedro's, Srinivas' and Hetal's ideas, but the user has to setup the development box for testing.
    I'll update later, thanks for your help. More ideas are appreciated!
    Pablo

  • How to find length of integer elements using message mapping

    Hi all,
             How can I find the number of digits in an element using message mapping
    XIer

    Satish,
               Cause I have to write the code for 100 elements, I have decided to have a AUDF with two inputs;
    1) for the element
    2) for the length of the data type (I am passing length using Constant message mapping func).
    Now when I change my UDF and try running it I get the following error:
    <b><i>Start of test
    Source code has syntax error:  /usr/sap/B06/DVEBMGS00/j2ee/cluster/server0/./temp/classpath_resolver/Map0999e66045cf11dcc83b4ebcfc11da82/source/com/sap/xi/tf/_MM_Recordcount1_.java:160: operator >= cannot be applied to int,java.lang.String if(Element_Name.length()>=Element_Length) ^ /usr/sap/B06/DVEBMGS00/j2ee/cluster/server0/./temp/classpath_resolver/Map0999e66045cf11dcc83b4ebcfc11da82/source/com/sap/xi/tf/_MM_Recordcount1_.java:166: operator <= cannot be applied to int,java.lang.String for(int i=Element_Name.length();i<=Element_Length;i++) ^ 2 errors</i></b>
    The code I have used is:
    public String Include_Space(String Element_Name,String Element_Length,Container container)
    {StringBuffer sb= new StringBuffer();
    if(Element_Name.length()>=Element_Length)
    return""Element_Name"";
    else
    for(int i=Element_Name.length();i<=Element_Length;i++)
    if(i==Element_Name.length())
    sb.append(Element_Name);
    else
    sb.append(" ");
    return ""sb.toString()"";
    Pls advice, where I am going wrong...
    XIer
    Message was edited by:
            XIer

  • How to change the order of target message? kindly help

    Hi Experts,
              I have a source message with fields EmpNo, EmpName, Dept and joining date. The target message has the same structure but fields are in different order. That is, EmpName, Dept, EmpNo and joiningdate.
    How to achive the target message with message mapping and without using a different message type for target?
    Kindly help
    Thanks
    Gopal

    Hi Gopal,
    Try this one.
    1. Create Only one message type of target type.
    2. Go to XSD tab and export the "XSD" of the message type.
    3. Change the <xsd:sequence> element to <xsd:all>
    4. Then import the "xsd" in external definitions.
    5. Use the imported "xsd" and create Message mapping. Give both source and target the same message type from XSD.
    6. just Map one to one.
    Now you can get ur required target structure. Since it is <xsd:all> it will accept ur input file.
    Regards,
    P.Venkat

  • Changes done in message mapping is not reflecting in output

    Hi all,
    i have created one scenario XML to XML and i before i had done 1 to 1 mapping, i got the output also.
    but when i changed few calculation in the message mapping
    there is one node "name" and "Description" in source and target in both places.
    i am having name in SOURCE XML as "something" but i want to change this name to "Xsomething" and in description i have something in source but i want to pass constant value "ZSUBHODIP".i did mapping in message mapping, and when i did the testing in message mapping then in target in message mapping
    i got "XCOPC_C03" and "ZSUBHODIP" but when it takes the XML file which is in my system then in output XML name value "XCOPC_C03" and description "ZSUBHODIP" is not coming.
    i activated it too.
    even i tried with the same FILE to FILE scenario also but in this scenario also problem is same like one one mapping only then when i changed it in message mapping then previous output is coming.
    is there server problem, if yes then how to fix it??
    please tell me what to do
    thanks

    Hi,
    can you test it like this:
    /people/michal.krawczyk2/blog/2005/09/16/xi-how-to-test-your-mapping-in-real-life-scenarios
    Regards,
    Michal Krawczyk

  • How do the Message mapping below issue

    Hi all.
            I am doing interface is Siebel to SAP Customer Creation and Update. While mapping source side Siebel pass the Customer Account Group are Sold to Party, Goods Recipient, Payer and Bill to Party based on these parameters .My Target side we want like Z001, Z002, Z003 and Z004.
    1) If Source side Customer Account Group is Sold to Party then my target side is Z001.
    2) If Source side Customer Account Group is Goods Recipient then my target side is Z002
    3) If Source side Customer Account Group is Payer then my target side is Z003
    4) If Source side Customer Account Group is Bill to Party then my target side is Z004
    So each time source Siebel send one Customer Account Group based on that we want target side as Z001, Z002, Z003, and Z004. So pls help to me <b>how do this issue on message mapping or user defined function (UTF)</b>
          please help me out .....
    Regards,
    Ramesh

    the best way to do it will be via value mapping
    http://help.sap.com/saphelp_nw04/helpdata/en/13/ba20dd7beb14438bc7b04b5b6ca300/frameset.htm
    in this case in future any change comes only your value mapping table needs to be altered unlike editing your UDF.
    Also ref: https://www.sdn.sap.com/irj/sdn/developerareas/xi?rid=/webcontent/uuid/a680445e-0501-0010-1c94-a8c4a60619f8 [original link is broken]
    to get value mapping on SDN TV.

  • How to change keyboard map fmrweb.res for different forms

    I'm using Oracle Forms 10g with Oracle Forms and Reports Application server 10g.
    I know how to change fmrweb.res to change how keys function on web forms. The problem I'm having is I only know how to assign the fmrweb.res file when connecting to the application server, which means all forms running on that session have to use the same keyboard mapping.
    I know you can change the defualt fmrweb.res for all the forms executed on the application server
    and you can change the fmrweb.res file in the URL like
    server/forms/frmservlet?Form=login.fmx&config=dataentry
    (where dataentry is defined in the formsweb.cfg file)
    and in the config section I have
    [dataentry]
    term=fullpath/fmrweb_new.res
    My question is, is there a way to pick a different fmrweb.res file based on the form?
    Can you specify multiple forms in the basexxx.htm file(basejini.htm) in the PARAM section like
    <PARAM NAME="serverArgs"
    VALUE="module=form1.fmx term=fillpath/filename1.res"
    VALUE="module=form2.fmx term=fillpath/filename2.res"
    VALUE="module=form3.fmx term=fillpath/filename3.res"
    VALUE="module=form4.fmx term=fillpath/filename4.res">
    Is there a way to pass term=fullpath\filename.res to the Oracle Forms Web Runtime process for each form using call_form, open_form, or new_form?
    Edited by: user537213 on Sep 19, 2008 5:38 PM
    Edited by: user537213 on Sep 19, 2008 6:24 PM

    Posiible approach (i now it sounds strange):
    Configure your enter-key to fire the KEX-EXEQRY-Trigger.
    In the dataentry-form-module: Overwrite the KEY-EXEQRY-Trigger so thtat is just does a NEXT_ITEM; .
    I know there may be other implications depending of the compelixity of your dataentry-form, but maybe this helps.

  • Email messages now show "To: me" instead of the name or email address and I want to know how to change back to the way it was.

    I use several yahoo email addresses and it has always been very convienent to see if it is a personal or business related message by simply seeing the To: line. Now all of sudden all I see is "me" and it is not at all helpful. I didn't make the change nor authorize it to be done. I am not even sure if this is a Firefox issue or a Yahoo issue. I would like to know how to change back to show the full email name or address.

    hello shackiraq, you'd have to contact yahoo's support about this issue - firefox doesn't handle your emails but just renders a website like it is provided to you by the server of a webmail service.
    https://help.yahoo.com/kb/mail-for-desktop

  • How to change reject call SMS message text

    Hello everyone
    Some time ago I bought a Nokia N9 and one feature I use frequently is reject calls sending a message.
    In other Nokia phones (symbian) you can change the message text in options section, but in this phone I can find how to change it.
    Do anyone know how to change this message?
    Thanks in advance

    Hi Amit,
    This can be done easily, if it showing the data of a view object then you can change the value of view attribute.
    Suppose a column in VO I say rank fetches value as 1,2,3 then in vo query to append L1,L2....
    Suppose I have quary like select rank from xx_table then I can change it to select 'L'||rank from xx_table.
    I hope this will resolve your problem.
    Regards,
    Reetesh Sharma

  • How to change the 'Default operating mode' of a mapping on the repository and not from the client

    Hi everybody,
    I am using OWB 11.2.0.3 and under the mapping's configuration property, I have the necessity to change the Run time parameter "Default operating mode" to SET_BASED in almost all my mappings.
    Because I have 745 mappings in which the Default operating mode is different from SET_BASED, instead to open 745 times the 'Configure' and update manually the value, is there a way to update safely these values (with an oracle predefined script) directly on the repository ?
    I know that exists a view called CMPSTRINGPROPERTYVALUE_V based on a table called CMPSCOPrpClasses, but changing this table it's very complicated for me because contains only keys and then I don't know in which way is connected with all the other structures....
    If somebody knows a method more efficient to do these updates on the repository and not from OWB client I will appreciated it!
    Thanks in advance
    Alessandro

    Urgent... help!!! Thanks
    in short, my server log says transaction access mode is "read only", so my calling home.create() always triggers a transaction rollback. How to change the access mode to "read write"?
    Is possible to work out through one of the descriptor files? Or ini settings of the underlying pointbase database? Or any other way around?

Maybe you are looking for