Hi
SAP +Integration using ALE
(Application Linking and Enabling)+[
- Introduction -
Introduction
Enterprises are increasingly looking to deliver real business benefits by integrating their systems and processes both within their organizations and between organizations. ng processes in this way, which requires tight integration, frequent communication and data exchange.
Highly integrated and inter-dependent SAP and non-SAP systems require frequent communication, tight integration and (usually) high levels of data exchange. In order to achieve this interoperability, SAP has come up with the concept of ALE (Application Linking and Enabling).
The idea behind ALE is to provide a more rigid integration service while allowing a high degree of independence to the individual SAP com
ge of business information across SAP and non-SAP systems. Applications are integrated by using synchronous and asynchronous communication without implementing a central database.
In this 7 article tutorial we will cover subjects such as:
Data Distribution Model
ALE process
IDOCS
Converters
Configuring ALE
Other concepts
***************************************************************
RFC
Purpose
Communication between applications of different systems in the SAP environment includes connections between SAP systems as well as between SAP systems and non-SAP systems. Remote Function Call (RFC) is the standard SAP interface for communication between SAP systems. The RFC calls a function to be executed in a remote system.
Synchronous RFC
The first version of RFC is synchronous RFC (sRFC). This type of RFC executes the function call based on synchronous communication, which means that the systems involved must both be available at the time the call is made.
Transactional RFC (tRFC)
Transactional RFC (tRFC, also originally known as asynchronous RFC) is an asynchronous communication method that executes the called function module in the RFC server only once. The remote system need not be available at the time when the RFC client program is executing a tRFC. The tRFC component stores the called RFC function, together with the corresponding data, in the SAP database under a unique transaction ID (TID).
If a call is sent, and the receiving system is down, the call remains in the local queue until a later time. The calling dialog program can proceed without waiting to see whether or not the remote call was successful. If the receiving system does not become active within a certain amount of time, the call is scheduled to run in batch.
tRFC is always used if a function is executed as a Logical Unit of Work (LUW). Within a LUW, all calls are
· executed in the order in which they are called
· executed in the same program context in the target system
· run as a single transaction: they are either committed or rolled back as a unit.
Implementation of tRFC is recommended if you want to guarantee that the transactional order of the calls is preserved.
Disadvantages of tRFC
· tRFC processes all LUWs independent of one another. Due to the amount of activated tRFC processes, this procedure can reduce performance significantly in both the send and the target systems.
· In addition, the sequence of LUWs defined in the application cannot be kept. Therefore, there is no guarantee that the transactions are executed in the sequence dictated by the application. The only guarantee is that all LUWs are transferred sooner or later.
Queued RFC (qRFC)
To guarantee that multiple LUWs are processed in the order specified by the application, tRFC can be serialized using queues (inbound and outbound queues). This type of RFC is called queued RFC (qRFC).
qRFC is therefore an extension of tRFC. It transfers an LUW (transaction) only if it has no predecessors (in reference to the sequence defined in different application programs) in the participating queues.
Implementation of qRFC is recommended if you want to guarantee that several transactions are processed in a predefined order.
RFC: Data Transfer
All RFC types are transferred by means of CPI-C or TCP/IP. They constitute a form of gateway communication.
Additional Information
· RFC Basics (BC-MID-RFC)
· The RFC API
· RFC Programming in ABAP
· Queued Remote Function Call (qRFC)
· SAP Gateway
*************************************************
IDoc (for intermediate document) is a standard data structure for electronic data interchange (EDI) between application programs written for the popular SAP business system or between an SAP application and an external program. IDocs serve as the vehicle for data transfer in SAP's Application Link Enabling (ALE) system. IDocs are used for asynchronous transactions: each IDoc generated exists as a self-contained text file that can then be transmitted to the requesting workstation without connecting to the central database. Another SAP mechanism, the Business Application Programming Interface (BAPI) is used for synchronous transactions.
A large enterprise's networked computing environment is likely to connect many geographically distributed computers to the main database. These computers are likely to use different hardware and/or operating system platforms. An IDoc encapsulates data so that it can be exchanged between different systems without conversion from one format to another.
IDoc types define different categories of data, such as purchase orders or invoices, which may then be broken down into more specific categories called message types. Greater specificity means that an IDoc type is capable of storing only the data required for a particular transaction, which increases efficiency and decreases resource demands.
An IDoc can be generated at any point in a transaction process. For example, during a shipping transaction process, an IDoc may be generated that includes the data fields required to print a shipping manifest. After a user performs an SAP transaction, one or more IDocs are generated in the sending database and passed to the ALE communication layer. The communication layer performs a Remote Function Call (RFC), using the port definition and RFC destination specified by the customer model. The IDoc is transmitted to the receiver, which may be an R/3, R/2, or some external system.
*******************************************************
is a set of interfaces to object-oriented programming methods that enable a programmer to integrate third-party software into the proprietary R/3 product from SAP. For specific business tasks such as uploading transactional data, BAPIs are implemented and stored in the R/3 system as remote function call (RFC) modules.
A good place to get started is this Introduction to BAPIs presented by sappoint.com.
SAP also provides this in-depth BAPI User Guide to help you master the basics. Terminology, rules for usage and prerequisites are included.
Also, SAP provides this BAPI Programming Guide
For ALE
http://www.thespot4sap.com/Articles/SAP_ALE_Introduction.asphttp://help.sap.com/saphelp_erp2004/helpdata/en/dc/6b835943d711d1893e0000e8323c4f/content.htmhttp://www.sapgenie.com/sapgenie/docs/ale_scenario_development_procedure.dochttp://edocs.bea.com/elink/adapter/r3/userhtm/ale.htm#1008419http://www.netweaverguru.com/EDI/HTML/IDocBook.htmhttp://www.sapgenie.com/sapedi/index.htmhttp://www.sappoint.com/abap/ale.pdfhttp://www.sappoint.com/abap/ale2.pdfhttp://www.sapgenie.com/sapedi/idoc_abap.htmhttp://help.sap.com/saphelp_erp2005/helpdata/en/0b/2a60bb507d11d18ee90000e8366fc2/frameset.htmhttp://help.sap.com/saphelp_erp2005/helpdata/en/78/217da751ce11d189570000e829fbbd/frameset.htmhttp://www.allsaplinks.com/idoc_sample.htmlhttp://www.sappoint.com/abap.htmlhttp://help.sap.com/saphelp_erp2004/helpdata/en/dc/6b835943d711d1893e0000e8323c4f/content.htmhttp://www.sapgenie.com/sapgenie/docs/ale_scenario_development_procedure.dochttp://edocs.bea.com/elink/adapter/r3/userhtm/ale.htm#1008419http://www.netweaverguru.com/EDI/HTML/IDocBook.htmhttp://www.sapgenie.com/sapedi/index.htmhttp://www.allsaplinks.com/idoc_sample.htmlFor RFC
http://help.sap.com/saphelp_nw04/helpdata/en/6f/1bd5b6a85b11d6b28500508b5d5211/content.htmhttp://help.sap.com/saphelp_nw04/helpdata/en/22/042518488911d189490000e829fbbd/content.htmhttp://www.planetsap.com/RFC.htmIDOC types are templates for specific message types depending on what is the business document, you want to exchange.
WE30 - you can create a IDOC type.
An IDOC with data, will have to be triggered by the application that is trying to send out the data.
FOr testing you can use WE19.
How to create idoc?
*WE30 - you can create a IDOC type
For more information in details on the same along with the examples can be viewed on:
http://www.netweaverguru.com/EDI/HTML/IDocBook.htm#_Toc8400404http://help.sap.com/saphelp_erp2005/helpdata/en/0b/2a6620507d11d18ee90000e8366fc2/frameset.htmhttp://www.sappoint.com/presentation.htmlhttp://www.allsaplinks.com/idoc_search.htmlhttp://www.sapgenie.com/sapedi/idoc_abap.htmhttp://www.erpgenie.com/sapedi/idoc_abap.htmTo Create Idoc we need to follow these steps:
Create Segment ( WE31)
Create Idoc Type ( WE30 )
Create Message Type ( WE81 )
Assign Idoc Type to Message Type ( WE82 )
Creating a Segment
Go to transaction code WE31
Enter the name for your segment type and click on the Create icon
Type the short text
Enter the variable names and data elements
Save it and go back
Go to Edit -> Set Release
Follow steps to create more number of segments
Create IDOC Type
Go to transaction code WE30
Enter the Object Name, select Basic type and click Create icon
Select the create new option and enter a description for your basic IDOC type and press enter
Select the IDOC Name and click Create icon
The system prompts us to enter a segment type and its attributes
Choose the appropriate values and press Enter
The system transfers the name of the segment type to the IDOC editor.
Follow these steps to add more number of segments to Parent or as Parent-child relation
Save it and go back
Go to Edit -> Set release
Create Message Type
Go to transaction code WE81
Change the details from Display mode to Change mode
After selection, the system will give this message The table is cross-client (see Help for further info). Press Enter
Click New Entries to create new Message Type
Fill details
Save it and go back
Assign Message Type to IDoc Type
Go to transaction code WE82
Change the details from Display mode to Change mode
After selection, the system will give this message The table is cross-client (see Help for further info). Press Enter.
Click New Entries to create new Message Type.
Fill details
Save it and go back
Check these out..
Check below link. It will give the step by step procedure for IDOC creation.
http://www.supinfo-projects.com/cn/2005/idocs_en/2/ALE/ IDOC
http://help.sap.com/saphelp_erp2004/helpdata/en/dc/6b835943d711d1893e0000e8323c4f/content.htmhttp://www.sapgenie.com/sapgenie/docs/ale_scenario_development_procedure.dochttp://edocs.bea.com/elink/adapter/r3/userhtm/ale.htm#1008419http://www.netweaverguru.com/EDI/HTML/IDocBook.htmhttp://www.sapgenie.com/sapedi/index.htmhttp://www.sappoint.com/abap/ale.pdfhttp://www.sappoint.com/abap/ale2.pdfhttp://www.sapgenie.com/sapedi/idoc_abap.htmhttp://help.sap.com/saphelp_erp2005/helpdata/en/0b/2a60bb507d11d18ee90000e8366fc2/frameset.htmhttp://help.sap.com/saphelp_erp2005/helpdata/en/78/217da751ce11d189570000e829fbbd/frameset.htmhttp://www.allsaplinks.com/idoc_sample.htmlhttp://www.sappoint.com/abap.htmlhttp://help.sap.com/saphelp_erp2004/helpdata/en/dc/6b835943d711d1893e0000e8323c4f/content.htmhttp://www.sapgenie.com/sapgenie/docs/ale_scenario_development_procedure.dochttp://edocs.bea.com/elink/adapter/r3/userhtm/ale.htm#1008419http://www.netweaverguru.com/EDI/HTML/IDocBook.htmhttp://www.sapgenie.com/sapedi/index.htmhttp://www.allsaplinks.com/idoc_sample.htmlhttp://www.sapgenie.com/sapgenie/docs/ale_scenario_development_procedure.docsgo trough these links.
http://help.sap.com/saphelp_erp2004/helpdata/en/dc/6b835943d711d1893e0000e8323c4f/content.htmhttp://www.sapgenie.com/sapgenie/docs/ale_scenario_development_procedure.dochttp://edocs.bea.com/elink/adapter/r3/userhtm/ale.htm#1008419http://www.netweaverguru.com/EDI/HTML/IDocBook.htmhttp://www.sapgenie.com/sapedi/index.htmhttp://www.sappoint.com/abap/ale.pdfhttp://www.sappoint.com/abap/ale2.pdfhttp://www.sapgenie.com/sapedi/idoc_abap.htmhttp://help.sap.com/saphelp_erp2005/helpdata/en/0b/2a60bb507d11d18ee90000e8366fc2/frameset.htmhttp://help.sap.com/saphelp_erp2005/helpdata/en/78/217da751ce11d189570000e829fbbd/frameset.htmhttp://www.allsaplinks.com/idoc_sample.htmlhttp://www.sappoint.com/abap.htmlhttp://help.sap.com/saphelp_erp2004/helpdata/en/dc/6b835943d711d1893e0000e8323c4f/content.htmhttp://www.sapgenie.com/sapgenie/docs/ale_scenario_development_procedure.dochttp://edocs.bea.com/elink/adapter/r3/userhtm/ale.htm#1008419http://www.netweaverguru.com/EDI/HTML/IDocBook.htmhttp://www.sapgenie.com/sapedi/index.htmhttp://www.allsaplinks.com/idoc_sample.htmlhttp://http://help.sap.com/saphelp_erp2004/helpdata/en/dc/6b835943d711d1893e0000e8323c4f/content.htmAn IDoc is simply a data container that is used to exchange information between any two processes that can understand the syntax and semantics of the data...
1.IDOCs are stored in the database. In the SAP system, IDOCs are stored in database tables.
2.IDOCs are independent of the sending and receiving systems.
3.IDOCs are independent of the direction of data exchange.
The two available process for IDOCs are
Outbound Process
Inbound Process
AND There are basically two types of IDOCs.
Basic IDOCs
Basic IDOC type defines the structure and format of the business document that is to be exchanged between two systems.
Extended IDOCs
Extending the functionality by adding more segments to existing Basic IDOCs.
To Create Idoc we need to follow these steps:
Create Segment ( WE31)
Create Idoc Type ( WE30)
Create Message Type ( WE81)
Assign Idoc Type to Message Type ( WE82)
imp links
http://www.allsaplinks.com/idoc_sample.html
http://www.sapgenie.com/sapedi/idoc_abap.htm
www.sappoint.com
--here u can find the ppts and basic seetings for ALE
http://sappoint.com/presentation.html
www.sapgenie.com
http://www.sapgenie.com/ale/index.htm
Check these links.
http://help.sap.com/saphelp_erp2004/helpdata/en/dc/6b835943d711d1893e0000e8323c4f/content.htm
http://www.sapgenie.com/sapgenie/docs/ale_scenario_development_procedure.doc
http://edocs.bea.com/elink/adapter/r3/userhtm/ale.htm#1008419
http://www.netweaverguru.com/EDI/HTML/IDocBook.htm
http://www.sapgenie.com/sapedi/index.htm
http://www.sappoint.com/abap/ale.pdf
http://www.sappoint.com/abap/ale2.pdf
http://www.sapgenie.com/sapedi/idoc_abap.htm
http://help.sap.com/saphelp_erp2005/helpdata/en/0b/2a60bb507d11d18ee90000e8366fc2/frameset.htm
http://help.sap.com/saphelp_erp2005/helpdata/en/78/217da751ce11d189570000e829fbbd/frameset.htm
http://www.allsaplinks.com/idoc_sample.html
http://www.sappoint.com/abap.html
http://help.sap.com/saphelp_erp2004/helpdata/en/dc/6b835943d711d1893e0000e8323c4f/content.htm
http://www.sapgenie.com/sapgenie/docs/ale_scenario_development_procedure.doc
http://edocs.bea.com/elink/adapter/r3/userhtm/ale.htm#1008419
http://www.netweaverguru.com/EDI/HTML/IDocBook.htm
http://www.sapgenie.com/sapedi/index.htm
http://www.allsaplinks.com/idoc_sample.html
http://www.sapgenie.com/sapgenie/docs/ale_scenario_development_procedure.docs
Please check this PDF documents for ALE and IDoc.
http://www.sappoint.com/abap/ale.pdf
http://www.sappoint.com/abap/ale2.pdf
http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCMIDALEIO/BCMIDALEIO.pdf
http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCMIDALEPRO/BCMIDALEPRO.pdf
http://help.sap.com/printdocu/core/Print46c/en/data/pdf/CABFAALEQS/CABFAALEQS.pdf
http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCSRVEDISC/CAEDISCAP_STC.pdf
http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCSRVEDI/CAEDI.pdf
Check below link. It will give the step by step procedure for IDOC creation.
http://www.supinfo-projects.com/cn/2005/idocs_en/2/
Creation of Custom IDOc type and message Type
First Create Partner Profile(WE20 Tcode) and Port Definition in WE19 Tcodes.
take the Basis help to create them.
1.First create segments in WE31 Tcode with the required dataelements
2.Create the Basic Idoc Type in WE30
release the Segments and IDOC type.
3.Create Message type in We81
4.Assign the message type to IDOC type in WE82 T code
5.Create the process code in We41 (for Outbound) WE42 (for Inbound)
6.Create A fun module in SE37 starting with ZIDOC_OUTPUT_.. by copying some Inbound (for Inbound) Outbound Fun module
7.Create Workflow setting if needed ..
8. Assign the fun module to Idoc Type, Message Type and WF object (if it is there0
9.Define setting for fun module in BD51
10.In BD51 Define the settings for Fun module..
10.Assign the Processs Code to Fun mod`ule
Reward all helpfull answers
Regards
Pavan