on 10-17-2008 5:47 AM
Hi,
I have a simple scenario of reading a mail and sending the content to RFC. I need a step by step approch how to configure this scenario. Appreciate the help.
Reagrds,
Manas
Hi
Do the folliowing
1. Import the RFC you want to send data (Inbound interface)
2. Create inteface for Mail that you need to read (Outbound interface)
3. Create mapping between Mail and RFC(Message and Interface mapping)
4. Configure Pipeline steps
5. Configure sender mail adapter
6. Configure receiver RFC adapter.
Refer already build blogs
Thanks
Gaurav
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Renu
You can use Mail package as Outbound interface. Check the basis component you can get Mail package there.
RFC when you import you can use that as Inbound interface.
Map Outbound to inbound interface using MM and IM
Use mail sender adapter to pick the mails from the Mail server.
Use RFC receiver(or any you want like FILE,IDOC etc) to send email content out of XI
Thanks
Gaurav
Hi Gaurav,
Thanks a lot. I am getting the following exception
com.sap.aii.utilxi.misc.api.BaseRuntimeException: RuntimeException in Message-Mapping transformation: Cannot produce target element /ns1:ZIB_PROCESS_CSV_FILE/FILE_CONTENT. Check xml instance is valid for source xsd and target-field mapping fulfills requirements of target xsd at
I did the following configuration in design time
1- Created MI_IB_MAIL_OB , which points to external mail. I imported the mail package xsd file through external defination
2- Created MI_IB_RFC_IB, which points to the RFC as type message
3- I ahve not create any Data type or message type, as already i mapped message intergace directly to RFC and Mail package
4- In the message mapping, i mapped the external mail type to RFC.
5 - In interface mapping , i mapped the MI_IB_MAIL_OB to MI_IB_RFC_IB , with mapping program as the name of the message mapping .
6- I configured both RFC and Mail Sender adapter in the configuration page.
After all these configurations i got the exception as metioned above. Its properly reading the mail .Let me know if i have done any thing wrong in the mapping part
Thanks a lot,
Manas
Hi Gurav,
What is Test feature to put in message mapping ?
Out of the mail i only need the body content to pass to the RFC.
Other parameters in RFC are constants. I dont map all elements from mail to RFC, except content.
My RFC structure
-
ZIB_PROCESS_CSV_FILE (RFC name - root element)
DOC_LOAD_DATE- element of type Date
DOC_LADE_TIME - element of type Time
EP_FILE_NAME - type string
File_CONTENT - type string
File_NAME- tyep string
Partner_ID - type string
User_ID - type string
Mail Structure
-
<xim:Mail xmlns:xim="http://sap.com/xi/XI/Mail/30">
<Subject>RE: consignment</Subject>
<From> </From>
<To></To>
<Content_Type> </Content_Type>
<Date></Date>
<Message_ID</Message_ID>
<Content> </Content>
</xim:Mail>
The Mail package xsd file through external definations
-
only i am using the Mail part in the xsd file
<?xml version="1.0" encoding="ISO-8859-1"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xi="http://bajajauto.com/IBNEW" targetNamespace="http://bajajauto.com/IBNEW">
<xs:element name="Mail">
<xs:annotation>
<xs:documentation>
Mail package for XI - Mail Adapter
</xs:documentation>
</xs:annotation>
<xs:complexType>
<xs:sequence>
<xs:element name="Subject" type="xs:string" minOccurs="0" />
<xs:element name="From" type="xs:string" minOccurs="0" />
<xs:element name="To" type="xs:string" minOccurs="0" />
<xs:element name="Reply_To" type="xs:string" minOccurs="0" />
<xs:element name="Content_Type" type="xs:string" minOccurs="0" />
<xs:element name="Date" type="xs:dateTime" minOccurs="0" />
<xs:element name="Message_ID" type="xs:string" minOccurs="0" />
<xs:element name="X_Mailer" type="xs:string" minOccurs="0" />
<xs:element name="Content" minOccurs="0">
<xs:annotation>
<xs:documentation>
any type
</xs:documentation>
</xs:annotation>
</xs:element>
</xs:sequence>
<xs:attribute name="encoding" type="xs:string" />
</xs:complexType>
</xs:element>
<xs:element name="MailReceipt">
<xs:annotation>
<xs:documentation>
Mail Receipt for XI - Mail Adaper
</xs:documentation>
</xs:annotation>
<xs:complexType>
<xs:sequence>
<xs:element name="Server" type="xs:string" />
<xs:element name="Format" type="xs:string" />
<xs:element name="UseMailPackage" type="xs:boolean" />
<xs:element name="Encoding" type="xs:string" />
<xs:element name="Subject" type="xs:string" minOccurs="0" />
<xs:element name="From" type="xs:dateTime" minOccurs="0" />
<xs:element name="To" type="xs:string" minOccurs="0" />
<xs:element name="Date" type="xs:dateTime" minOccurs="0" />
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:schema>
Let me know if all are configured properly
Regards,
Manas
Edited by: Renu Nair on Oct 18, 2008 8:29 AM
HI
Test feature is nothing but the test tag
When you check your mapping in test tag is it showing some error. In case no then you have issue with RFC only. First figure is it really a mapping error. As you are using almost constants it should not give error.
Check once doing a test and see all target nodes are generated as per your requirement.
Thanks
Gaurav
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
81 | |
10 | |
10 | |
9 | |
7 | |
6 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.