MESSAGE MAPPING FROM SQL TO RFC(BAPI)

Hello Guys,
Im just new here in SAP XI version 7.0 . Can anyone teach me how to map objects using IR (design) between sender (data coming from sql 2005) and receiver (using Bapi_Salesorder_Createfromdat2)?
there are only specific fields i need to transfer the data like the followings :
do i need to map all fields from sender to receiver?tell me how..
*ORDER_HEADER_IN
-DOC_TYPE = ZTRV
-SALES_ORG =4000
-DISTR_CHAN =40
-DIVISION=41
-SALES_OFF=4101
-SALES_GRP=411
-PURCH_NO_C='TEST TPL1' (MUST BE UNIQUE)
-PMNTTRMS =Z015
-PURCH_DATE=09/04/2008
*ORDER_PARTNERS
-PARTN_ROLE= AG
-PARTN_NUMB=1100074
Thanks in advance
aVaDuDz

Hi,
Create :
1. Source & Target Data Types
2. Messge Type (for source & target data types)
3. Two Message Interface for using above message types
4. One Message mapping using source & target message Type
5. One Interface mapping.
In message mapping just map those field which you require. You can leave rest of the fileds un mapped at source which are not required to map.
Regards,
Sarvesh

Similar Messages

  • Problem by transporting the message mapping from PI 7.0 to PI 7.1

    Hi Everyone,
    by transporting the message mapping from PI 7.0 to PI 7.1 i have got the following problem.
    "Source code has syntax error:
    K:\usr\sap\E71\DVEBMGS00\j2ee\cluster\serve......
    package udfpool does not exist
    import udfpool.*;
    i have used a UDF in my message mapping.
    This UDF calls for a method of a java class, which is imported as a .jar file with this message mapping.
    this message mapping works very well on PI 7.0,
    but doesn't work any more on PI 7.1 because of the problem described above.
    anyone can help me out of this problem?
    thanks!
    zc

    hi,
    but did you import the jar archive to 7.1 first?
    Regards,
    Michal Krawczyk
    http://mypigenie.com XI/PI FAQ

  • Re-use message mapping from within java mapping?

    Hi there,                                                                               
    I have a question regarding java mapping. What I would like to do is to re-use an existing message mapping from within java mapping.
    Technicaly, message mapping is perfomed by com.sap.aii.mappingtool.tf3.AMappingProgram.execute, right? I would like to call that mapping program for a specifc message mapping from within my java mapping.
    Pseudo java code would look like this:
    public void execute(InputStream in, OutputStream out)
      throws StreamTransformationException {
    com.sap.aii.mappingtool.tf3.AMappingProgram.execute(in,out,'SomeMessageMapping');
    SomeMessageMapping is a message mapping that is defined in the integration repository.
    Is it possible? If so, could you provide me with some details?
    Thank you and best regards,
    Wolfgang

    Hi Wolfgang,
    very interesting idea?
    I would activa a dummy message mapping. than I would have a look in the file directory of the java-stack and try to find out the name of the *.class or *.jar file.
    On the other hand you could generate a tpz-transport-file an unpack this file, to explore the name of the *.class or *.jar
    Unfortunately I do not have access to the file system. So I can't explore the name.
    Regards Mario

  • Message mapping transformation error for RFC calls

    Hi,
    I am having a weird problem. recently client migrated the server and we started getting all possible errors in XI which we are able to fix. Now we have a strange problem in quality system alone where the bapi calls are made from QA11 and MIGO. The bapi call from MIGO is sucessfull but from QA11 it fails with below error
    com.sap.aii.utilxi.misc.api.BaseRuntimeException
    thrown during application mapping
    com/sap/xi/tf/_MP_RFC_PROXY_GOODS_RECEIPT_:
    RuntimeException in Message-Mapping transformatio~
    I checked in development system and production where it is sucessfull but in quality its failing. I checked the cache and refreshed for confirmation and checked the trace and log files but couldt find any solution. The call made from a test report is also sucesfull but only bapi calls from QA11 are failing.
    Note: i am using same bapi in MIGO and QA11 and the integration is same as well. There is no difference in data between 2 transaction just the trigerring point is differenct.
    I tested my message mapping, interface mapping and configuration as well with sample payload and they are working fine.
    I checked SDN and saw that similar issue is faced by others but no solution is provided.
    Regards,
    Jayaram
    Edited by: JAYARAM MAGANTI on Jun 9, 2009 1:14 PM

    Hi all,
    Has anyone ever faced this issue?
    i tried all the options that i think of and as a last attempt even restarted XI engine though it makes no sense. but still i am having the same issue.
    If anyone had come across similar kindly update the solution
    Jayaram

  • Message Mapping fails because of RFC

    Guys,
    1) I have some messages failed in SXMB_MONI because message mapping for those interfaces was not executed successfully. In trace I can see the following:
    "com.sap.mw.jco.JCO$Exception: (102) RFC_ERROR_COMMUNICATION: Connect to SAP gateway failed Connect_PM TYPE=A ASHOST=121.12.2.15 SYSNR=02 GWHOST=121.12.2.15 GWSERV=sapgw02 PCS=1 LOCATION CPIC (TCP/IP) on local host with Unicode ERROR partner not reached (host ?, service ?) TIME Wed Jul 11 07:20:27 2007 RELEASE 640 COMPONENT NI (network interface) VERSION 37 RC -10 COUNTER 1024</Trace>"
    I realize it is a network connection problem, but..
    Any ideas?
    2) Actually, in my mapping programs I have to perform many RFC's to both XI and target/source SAP systems, in order to get some information. The techique that I am using for RFC's is through Java's com.sap.mw.jco.* package. And I connect to systems by giving the IP address, system number, username and password of the systems and then I execute the remote enabled function modules.
    However. when I have many RFC's some of them fail, maybe because the maximum number is reached. And then I have to manually restart them from SXMB_MONI and they are successfully processed.
    Any ideas?

    But you said you call many RFCs inside XI, right?
    The proper way of doing it is not using JCo directly, but using Mapping Lookup API instead. In this way, you won't need to maintain the connection details inside the code, but in the communication channels.
    Check this out: https://help.sap.com/javadocs/NW04S/current/pi/index.html (lookup api).
    There are some code examples within the classes (for example, RfcAcessor).
    I think there is also a SDN documentation by Michal Krawczyk regarding RFC Lookups.
    Just search for it.
    Regards,
    Henrique.

  • Message Mapping from flat XML to a Record structure

    Hi All,
    We have a scenario in which the input message is a PDF document. we are following below the blog to convert PDF to XML format which uses <b>PDF box utitlity</b>.
    /people/sap.user72/blog/2005/07/31/xi-read-data-from-pdf-file-in-sender-adapter
    We are able to convert the PDF doc to a flat XML file.
    Now we have the following queries...
    what are the different ways to map the flat XML to our record structure?
    Do we have any utitlity in PDF box to do that?
    Regards,
    Rakesh.

    Hi Rakesh,
    You have Graphical mapping, Java mapping, ABAP mapping and XSLT mapping. The choice depends on the scenario and what target result you require.
    <b>Message mapping using graphical mapping editor:</b>
    http://help.sap.com/saphelp_nw04/helpdata/en/49/1ebc6111ea2f45a9946c702b685299/frameset.htm
    <b>XSLT mapping:</b>
    http://help.sap.com/saphelp_nw04/helpdata/en/73/f61eea1741453eb8f794e150067930/frameset.htm
    <b>Java Mapping:</b>
    http://help.sap.com/saphelp_nw04/helpdata/en/e2/e13fcd80fe47768df001a558ed10b6/frameset.htm
    <b>ABAP mapping:</b>
    http://help.sap.com/saphelp_nw04/helpdata/en/ba/e18b1a0fc14f1faf884ae50cece51b/frameset.htm
    As said earlier, graphical mapping is the simplest and quite a few built in options are available with it, explore it and see which is suitable for your scenario.
    Regards,
    Chandra

  • How to do message mapping in IDoc or RFC to file transfer ?

    Hello guys. I have a doubt. I know how to do an IDoc to file or RFC to file scenario. But how to do mapping in an Idoc to file or RFC to file scenario ? As I understand mapping is done in the sender. But IDoc or RFhas no interface as its used for SAP. So where do we need to perform mapping ?

    Hi,
    You dont need the Data type and message type for IDOC's, RFC's and for external definitions. so u just create one DT,MT for your File structure and you need 2 message interfaces, one for file and one for the Idoc/RFC. You can use them in your mapping program.
    Regards,
    Kumar.
    P.S: Reward Points if Helpful!!!!!!!!!

  • How to "get" message mapping from XI scenario

    Hi guys!
    Is there a way, how to export message mapping description in some way from PI? In XI 3.0 it was possible, but what about PI 7.0? Hope you understand me:)
    We need it to save this mm description as documentation.
    Thanx a lot!
    Olian

    Hey Oilan,
    with the message mapping open, hold ctrl + shift and right-click in the data-flow editor (the part of the screen where the function boxes and links go).
    a different menu will pop-up. just follow "export tools, export" or something like that. It is pretty straightforward.
    It will save the mapping in a .mte (or something like that) extension file. It is nothing but an XML. Good thing is that you can also import this .mte file in another message mapping (of course, with same source and target messages, or it won't be able to reference the links).
    Regards,
    Henrique.

  • (262119469) Q DBC-17 How is data mapped from SQL-type to Java-type?

    Q<DBC-17> Is there any documentaion for the data mapping between the "java type" and
    the "sql type"
    A<DBC-17> The data types are the standard JDBC mappings. Check the javadoc for the
    java.sql package.

    Hi,
              If you are seeing last 3 fields coming as empty.... then you need to check the seperator type which correctly seperats one fields from another during mapping to BW infoobject.
    Thanks
    Kishore Kusupati

  • Data Type Mapping from SQL server to Oracle

    I am using Oracle 12c with heterogenous services connecting to SQL server DB. Some of the columns in the SQL server SB are defined as 'nvarchar(max)'. These are coming over to Oracle as 'long' type columns. I would like these to be 'varchar2' types in Oracle so I do not have any of the restrictions related to 'long' type fields when using. I can create a view in SQlServer to convert the data type ie. nvarchar(100). What is the highest value I can use to make the data show in Oracle as varchar? BTW  I tried nvarchar(4000) but that still showed as long. I tried nvarchar(1000), and that did show as varchar.

    The maximum value for a nvarchar2 in Oracle is 2000. The mapping -if the remote column is mapped to an Oracle varchar/nvarchar- depends on the data type returned by the ODBC driver. When the driver returns SQL_Varchar, then the maximum precision is 4000 and when it will map it to SQL_WVarchar then it is 2000.
    As your Oracle database uses AL32UTF8 as character set you will get the nvarchar(max) mapped to Oracle longs as the content of your SQL Server nvarchar is stored using UCS2 character set which is covered by the Oracle database charset UTF8. So it shouldn't really matter if the returned string is mapped to an Oracle varchar or nvarchar.

  • Function to call Process-flows/mapping from SQL

    Hi All,
    Can any one of you send me the function to call process-flows/mappings (eg: I have 10 mapping/Process-flows). It is an urgent requirement pending in my final testing.
    Plz help me in this regard.
    Regards

    Hi
    All information that you need, you can find in $ORACLE_HOME/owb/rtp/sql/. BAsically all executions in owb is called through wb_rt_api_exec package.
    for example:
    declare
         variable exec_return_code number;
         procesflow varchar2(255);
    plsqlname varchar2(255);
    begin
    -- Initialize Return Code
    exec_return_code := owbrt_sys.wb_rt_api_exec.RESULT_FAILURE;
    -- Run Task
    procesflow:='WF_X1';
    plsqlname:='MP_X1'
    exec_return_code := owbrt_sys.wb_rt_api_exec.run_task('OWF_LCTN','PROCESS',procesflow, ' ' );
    if exec_return_code = 1 then
    exec_return_code := owbrt_sys.wb_rt_api_exec.run_task('STAGE_LCTN','PLSQL',plsqlname, ' ' );
    end if;
    end;
    Regards

  • Reverse engineering OWB (11.2) maps from SQL

    Hi,
    Is there a way to reverse engineer SQL code into OWB Maps using Experts. I have seen one for older version of OWB, but wondering if it's possible (or can one use the same downloads) for the new version.
    http://blogs.oracle.com/warehousebuilder/2007/08/sql_and_owb_accelerated_map_co.html
    Thanks.

    Use the same MDL it will be upgraded when you import the MDL, any problems let me know.
    Cheers
    David

  • Message mapping from 0..1 to 1 (IDoc to JDBC)

    Hi,
    My Scenario is IDoc to JDBC. I have a field in IDoc which is optional, this optional filed is mapped to a mandatory field in JDBC.
    If the optional filed in IDoc doesn't exist, then mapping between Optional field and mandatory field is not happening and hence the mandatory field is becoming null which is throwing error in JDBC.
    Can any one guide me in how to map these fields and even if optional field in IDoc doesn't exits, a constant 'false' should be filled in mandatory field.

    Hi
    Use mapwithdefault standard function. so even if your optional field does not occur then a blank value will still be pased to your target field.
    Also you can check if your optional field exitst, if it does not then pass a blank constant else pass your value.
    You can use any of the above 2
    FIELDNAME->MAPWITHDEFAULT->TARGET
    Hope this solves your issue
    THanks
    Saiyog

  • Retrive message mapping error from java class

    Hi,
    I'm trying to create a scenario that if exist an error in the message mapping step this error will be inserted in a Ztable. I'm thinking in to call to the message mapping from a java class to catch the exception and this java class will be used in the interface mapping.
    Is it possible? If yes, How to call the message mapping from java code?
    Exists other possible solution?
    I need to do it because we want store all mapping errors in a Ztable. (Customer requeriment)
    Thanks, in advance
    Jose Manuel

    you can throw generic exceptions from the message mapping like this - /people/michal.krawczyk2/blog/2007/04/26/xipi-throwing-generic-exceptions-from-any-type-of-mapping
    you can then decide how to handle these exceptions

  • Message mapping hangs when selecting communication channel

    Hi Experts,
    I have a strange problem. In message mapping, there is an RFC Lookup. For this RFC lookup, there is one parameter of type communication channel. I want to test this message mapping. So, I go to the Test tab and browse for all available communication channels. When I select a channel and click on Select, ESR hangs. I am not getting why this is happening. Please help me get rid of this problem.
    Thanks,
    Netrey

    Hi,
    Got solution for this problem. Below is the communication from SAP on this issue,
    Please apply the latest patch levels for the PI components, following
    the steps below:
    http://service.sap.com/swdc
    1. Software Downloads - SAP Software Distribution Center
    2. Support Packages and Patches - Entry by Application Group
    3. SAP NetWeaver and complementary products - SAP NETWEAVER PI
    4. SAP NETWEAVER PI 7.1 - Entry by Component
    5. Process Integration. The components that should be updated are:
    ESR 7.10
    MESSAGING SYSTEM SERVICE 7.10
    XI ADAPTER FRAMEWORK 7.10
    XI ADAPTER FRAMEWORK CORE 7.10
    XI TOOLS 7.10
    Thanks and Regards,
    Netrey

Maybe you are looking for

  • Cable to connect audio out to TV?

    What kind of cable do I need to get audio from my iBook G4 to play (along w/ the video, whose cable I have) through my TV? Is it this 1: http://store.apple.com/us/product/TN983LL/A?mco=MzE2OTkzMQ Thanks, Nick

  • Motion Will Not Open

    I click motion in the dock... the arrow bounces underneath the icon several times and disappers. This is error that appears in the console. dyld: Library not loaded: /System/Library/PrivateFrameworks/LiveType.framework/Versions/A/LiveType Referenced

  • HT201342 What are the benefits to using @icloud account over @me. account?

    Do I need to change over to @icloud account for email and what are the benefits over @me account?

  • Bank Select with Famton X7 and Logic Sttudio

    Hi, I'm a new user of Logic Studio and of this forum ... but I'm familiar with MIDI. My Question: How can I send the right MSB and LSB for a program change to the Roland Fantom X? For example the Patch *PRA 001* (So far ...) There is only one Program

  • Error signing AIR applicaiton

    I recently purchased a code signing certificate from Thawte. The cert was imported into Firefox, and then exported as a P12 file, with a password. In flex builder, I tried to export my project and selected the certificate and typed the password, but