‎2007 Apr 12 12:54 PM
hi all,
Can any body provide the code to upload purchase order data using bapis in lsmw.urgent pls...
thanks.
assad
‎2007 Apr 12 1:02 PM
Hi,
Give the parameters like this in the intial stage .
1.Business Object : BUS2012
2.Bapi : CreateFromData
3.Message Type : PORDCR
4.Basic Type : PORDCR02
After this
Do the settings for the IDOC INBOUND Processing
mentioning FILEPORT, PARTNER TYPE , PARTNER NUMBER
after this step . proceed with ur steps . declare 2 structure . one for header & other for Item
Map the releveant structures with std structure
do the fiedl mapping . specify the files . assign the files & then continue with the other steps.
let me know , if u have any questions
Thanks,
Manjunath MS
"Reward Points if it is useful"
‎2007 Apr 12 1:02 PM
Hi,
Give the parameters like this in the intial stage .
1.Business Object : BUS2012
2.Bapi : CreateFromData
3.Message Type : PORDCR
4.Basic Type : PORDCR02
After this
Do the settings for the IDOC INBOUND Processing
mentioning FILEPORT, PARTNER TYPE , PARTNER NUMBER
after this step . proceed with ur steps . declare 2 structure . one for header & other for Item
Map the releveant structures with std structure
do the fiedl mapping . specify the files . assign the files & then continue with the other steps.
let me know , if u have any questions
Thanks,
Manjunath MS
"Reward Points if it is useful"
‎2007 Apr 12 1:22 PM
hi Manujunath,
If Possible can u just throw some more light wats happening internally since generating the flat files and uploading it to the idocs since i am new to lsmw.
Thanks once again.
assad
‎2007 Apr 12 1:35 PM
BAPIs are normally called synchronously in order to get feedback immediately.A synchronous call will only work if the system we want to access is up and running.For some purposes like data transfer, SAP wanted BAPIs to invoke asynchronously so that the calling application could proceed even if the remote system was currently unavailable.
Hence these BAPIs are linked to ALE (Application Linking and Enabling),an asynchronous message passing mechanism with guaranteed delivery.ALE uses Idocs as the containers for messages. Idocs are instances of Idocs types, which in turn are associated ALE message types
SAP has provided a generator which takes a BAPI and generates an appropriate ALE message type and an associated Idoc type.
Data stored in a file by means of the IDoc technique is generally imported in two steps. You can call these steps in LSM Workbench:
Start IDoc creation.
First, the file of the converted data is read. The "information packages" contained are stored in the R/3 database in IDoc format. It is, however, not stored in the database of the corresponding application. The system assigns a number to every IDoc. Then the file of the converted data is deleted.
Start IDoc processing.
The IDocs created in the first step are submitted to the corresponding application program. This application program checks the data and posts it in the applications database, if applicable.
Thanks,
Manjunath MS
"Reward Points if it is useful"
‎2007 Apr 13 6:55 AM
Hi Assad Hussain,
Check this info.
BAPI with LSMW
http://esnips.com/doc/ef04c89f-f3a2-473c-beee-6db5bb3dbb0e/LSMW-with-BAPI
For document on using BAPI with LSMW, I suggest you to visit:
http://www.saptechnical.com/Tutorials/LSMW/BAPIinLSMW/BL1.htm
Hope this resolves your query.
Reward all the helpful answers.
Regards
‎2007 Apr 13 6:59 AM
Hi Assad,
Step-by-Step Procedure:
Details of the BAPI used in this scenario:
Business Object: BUS2012
Method: CreateFromData
Details of Message Type and Basic IDoc Type:
Message Type: PORDCR
Basic IDoc Type: PORDCR02
Lets have a look at the BAPI first, before proceeding to the LSMW:
1. Go to Transaction BAPI
2. Click on Search Button
3. Enter the value BUS2012 and select Obj.type(Technical Object Name
Check the URL:
Check this info.
BAPI with LSMW
http://esnips.com/doc/ef04c89f-f3a2-473c-beee-6db5bb3dbb0e/LSMW-with-BAPI
For document on using BAPI with LSMW, I suggest you to visit:
http://www.saptechnical.com/Tutorials/LSMW/BAPIinLSMW/BL1.htm
Hope this resolves your query.
Reward all the helpful answers.
Regards,