BDC/BAPI for MI04
Hi,
I have a requirement where I need to develop a upload program (from flat file) for MI01 and MI04 t-code. I have created a BDC for MI01 t-code which is running successfully. But I cant able to create the same for MI04 t-code. And also I didnt find any such kind or MI04. instead I found a lot of posts suggesting for BAPI (instead of BDC).
After all this I decided to go for BAPI which I haven't developed till now. With this situation I searched it (BAPI for MI04) in the forum. But I could not find a complete code. In almost all the posts, only part of the code i.e FM's are listed. As I am new to the BAPI, I was searching for a complete code (BAPI for MI04).
Can anyone post the BAPI code for MI04 transaction.
Regards,
Praveen
use ''BAPI_MATPHYSINV_COUNT' bapi...
u have to fill all the structures or ITAB which are mandatory. Then pass them to this BAPI. after that use BAPI_TRANSACTION_COMMIT to update the database
and how to create .txt file to upload data to this transaction.
the text file should contain all the fields which are necessary to pass to bapai structures /ITABs
better , u can run the corresponding trn.. to know all mandt fields
U can use GUI_upload to upload the flat file.
Reward if useful
Similar Messages
-
BDC / Bapi For Post Incoming Payment (F-28)
Hi
Im creating BDC for F-28. But it got error coming out.
>> It says DB05B-PSZAH(02) is not an input field.
What I do is: First, I search for Line Item then Document Number. Then It return to basic list. Then I loop again for the second Line Item Number and Document Number.
I can activate the first amount but cannot for the next amount and so on.
Anybody could help me on this??
Is there any BAPI for Post Incoming Payment (F-28)?
Thank you.
Regards.i dont think there is a BAPI for this Transaction...
i have done a BDC on F-28 myself....pasting the code....hope it helps you....
*******NOTE********
the parameter in the subroutine is to see if there is a single document or multiple documents being posted.
FORM fill_bdc_data_f-28_9005 USING p_i_mult_doc TYPE c.
**BDC from screen 9005
DATA : l_amt_bdc(13), l_amt_bdc_remain(13), l_amt_bdc_mult(13),
l_amt_bdc_mult_remain(13), l_assignment(14), l_period(2),
l_amount(13).
CLEAR t_bdcdata.
REFRESH t_bdcdata.
PERFORM bdc_dynpro USING 'SAPMF05A' '0103'.
PERFORM bdc_field USING 'BDC_OKCODE' '=AB'. "OK CODE - doc overview
**get user default date format and pass date in that format
PERFORM convert_date_to_user_format USING bkpf-bldat.
PERFORM bdc_field USING 'BKPF-BLDAT' w_date. "cheque date
CLEAR w_date.
PERFORM bdc_field USING 'BKPF-BLART' i_blart. "doc type
PERFORM bdc_field USING 'BKPF-BUKRS' i_bukrs. "comp code
**get user default date format and pass date in that format
PERFORM convert_date_to_user_format USING bkpf-budat.
PERFORM bdc_field USING 'BKPF-BUDAT' w_date. "posting date
CLEAR w_date.
l_period = sy-datum+4(2).
PERFORM bdc_field USING 'BKPF-MONAT' l_period. "period
PERFORM bdc_field USING 'BKPF-WAERS' 'INR'. "currency
PERFORM bdc_field USING 'BKPF-BKTXT' i_bankl. "doc. hdr. text
PERFORM bdc_field USING 'BKPF-XBLNR' i_xblnr. "Ref. Document No.
PERFORM bdc_field USING 'BSEG-ZUONR' i_zuonr. "Assignment(Depot Code)
PERFORM bdc_field USING 'RF05A-KONTO' i_bank_gl. "Bank GL acc
PERFORM bdc_field USING 'BSEG-GSBER' i_gsber. "Business Area
l_amount = bseg-wrbtr.
PERFORM bdc_field USING 'BSEG-WRBTR' l_amount. "Amount
PERFORM bdc_field USING 'BSEG-PRCTR' ''. "Profit Center
**open items data
PERFORM bdc_field USING 'RF05A-AGKOA' 'D'. "Acc type (D=customers)
PERFORM bdc_field USING 'RF05A-XNOPS' 'X'. "Std OIs check box
**end of first screen
**document overview screen
PERFORM bdc_dynpro USING 'SAPMF05A' '0700'. "Overview Screen
PERFORM bdc_field USING 'BDC_CURSOR' 'RF05A-AZEI1(01)'. "cursor
PERFORM bdc_field USING 'BDC_OKCODE' '/00'. "OK CODE
PERFORM bdc_field USING 'RF05A-NEWBS' '19'. "posting key
PERFORM bdc_field USING 'RF05A-NEWKO' i_kunnr. "customer
PERFORM bdc_field USING 'RF05A-NEWUM' 'B'. "Spl GL Indicator
**for single document selected
CLEAR l_amt_bdc.
IF p_i_mult_doc = ''.
***new screen - next line item
PERFORM bdc_dynpro USING 'SAPMF05A' '0303'.
PERFORM bdc_field USING 'BDC_OKCODE' '=BU'. "OK CODE
**for single document, use the bouncing amount calculated earlier
l_amt_bdc = w_amt_ant_bouncing.
PERFORM bdc_field USING 'BSEG-WRBTR' l_amt_bdc. "amount
**due date - same as posting date on screen
**get user default date format and pass date in that format
PERFORM convert_date_to_user_format USING bkpf-budat.
PERFORM bdc_field USING 'BSEG-ZFBDT' w_date. "due date
CLEAR w_date.
**assignment
CLEAR l_assignment.
CONCATENATE t_seldoc_ant_bouncing-belnr
t_seldoc_ant_bouncing-gjahr INTO l_assignment.
PERFORM bdc_field USING 'BSEG-ZUONR' l_assignment. "assignment
PERFORM bdc_field USING 'BSEG-GSBER' i_gsber.
**if there is some remaining amount, then go for another line item
IF w_rem_amt_ant_bouncing > 0.
PERFORM bdc_field USING 'RF05A-NEWBS' '15'. "posting key
PERFORM bdc_field USING 'RF05A-NEWKO' i_kunnr. "customer
**new screen
PERFORM bdc_dynpro USING 'SAPMF05A' '0301'.
PERFORM bdc_field USING 'BDC_CURSOR' 'BSEG-ZTERM'. "CURSOR
PERFORM bdc_field USING 'BDC_OKCODE' '=BU'. "OK CODE-ENTER
l_amt_bdc_remain = w_rem_amt_ant_bouncing.
PERFORM bdc_field USING 'BSEG-WRBTR' l_amt_bdc_remain.
PERFORM bdc_field USING 'BSEG-ZTERM' '0001'.
**AGAIN
PERFORM bdc_dynpro USING 'SAPMF05A' '0301'.
PERFORM bdc_field USING 'BDC_CURSOR' 'BSEG-WRBTR'. "CURSOR
PERFORM bdc_field USING 'BDC_OKCODE' '=BU'. "OK CODE-SAVE
PERFORM bdc_field USING 'BSEG-WRBTR' l_amt_bdc_remain.
PERFORM bdc_field USING 'BSEG-ZTERM' '0001'. "pmt term -hardcoded
PERFORM bdc_field USING 'BSEG-SKFBT' l_amt_bdc_remain.
ENDIF.
**multiple documents
ELSE.
**initialize remaining amount to amt entered on screen
l_amt_bdc_mult_remain = bseg-wrbtr.
LOOP AT t_seldoc_ant_bouncing.
IF l_amt_bdc_mult_remain > 0.
IF bseg-wrbtr > t_seldoc_ant_bouncing-rem_amt.
l_amt_bdc_mult = t_seldoc_ant_bouncing-rem_amt.
ELSE.
l_amt_bdc_mult = bseg-wrbtr.
ENDIF.
**remaining amt = screen amt - amt calculated above.
l_amt_bdc_mult_remain = l_amt_bdc_mult_remain - l_amt_bdc_mult.
PERFORM bdc_dynpro USING 'SAPMF05A' '0303'.
PERFORM bdc_field USING 'BDC_OKCODE' '=BU'. "OK CODE
PERFORM bdc_field USING 'BSEG-WRBTR' l_amt_bdc_mult. "amount
PERFORM bdc_field USING 'BSEG-GSBER' i_gsber. "Business Area
**due date - same as posting date on screen
**get user default date format and pass date in that format
PERFORM convert_date_to_user_format USING bkpf-budat.
PERFORM bdc_field USING 'BSEG-ZFBDT' w_date. "due date
CLEAR w_date.
**assignment
CLEAR l_assignment.
CONCATENATE t_seldoc_ant_bouncing-belnr
t_seldoc_ant_bouncing-gjahr INTO l_assignment.
PERFORM bdc_field USING 'BSEG-ZUONR' l_assignment. "assignment
**posting key 19 for all but last document
PERFORM bdc_field USING 'RF05A-NEWBS' '19'. "posting key
PERFORM bdc_field USING 'RF05A-NEWKO' i_kunnr. "customer
PERFORM bdc_field USING 'RF05A-NEWUM' 'B'. "Spl GL
ENDIF.
ENDLOOP.
ENDIF.
**post remaining amount
IF p_i_mult_doc = 'X'.
**new screen if there is some amount left
IF l_amt_bdc_mult_remain > 0.
**posting key 15 with remaining amount
PERFORM bdc_field USING 'RF05A-NEWBS' '15'. "posting key
PERFORM bdc_field USING 'RF05A-NEWKO' i_kunnr. "customer
PERFORM bdc_field USING 'RF05A-NEWUM' ''. "Spl GL
**new screen
PERFORM bdc_dynpro USING 'SAPMF05A' '0301'.
PERFORM bdc_field USING 'BDC_OKCODE' '=BU'. "OK CODE
PERFORM bdc_field USING 'BSEG-WRBTR' l_amt_bdc_mult_remain.
PERFORM bdc_field USING 'BSEG-ZTERM' '0001'. "pmt term - hardcoded
ELSE.
**if no amount is left, no need for a further line item
PERFORM bdc_field USING 'RF05A-NEWBS' ''. "posting key
PERFORM bdc_field USING 'RF05A-NEWKO' ''. "customer
PERFORM bdc_field USING 'RF05A-NEWUM' ''. "Spl GL
ENDIF.
ENDIF.
**clear variables
CLEAR : l_amount, l_assignment, l_amt_bdc,
l_amt_bdc_remain,l_amt_bdc_mult, l_amt_bdc_mult_remain.
ENDFORM. " fill_bdc_data_F-28_9005 -
BDC/BAPI for set delivery cmlition indicator in purchase order @ item level
Hi Expert,
could you please suggest me bapi to set/reset delivery completion indicator in purchase order at item level for t-code "ME22n"?
Thanks and regard,
Santosh GuptaUse BAPI_PO_CHANGE to set the delivery completed indicator.
Refer to table section in the BAPI Interface
POITEM LIKE BAPIMEPOITEM
POITEMX LIKE BAPIMEPOITEMX
Set Field POITEM-NO_MORE_GR = 'X' & Set field POITEMX-NO_MORE_GR = 'X' -
Function module/BDC/BAPI for Component allocation operation wise
Dear Experts,
I need your help on Component allocation in Routing (CA02) per opertion wise.
Currently we are assigning the Component individually per operation manually
The problem is if a BOM is having 500 Components/Materials and there are 10 operations then we need to assign these 500 components to that particular operation manually which is tedious job & killing a lot of time.
I need your help if any Function module or BAPI or BDC is there to allocate these components per operation wise.
Or any other process which can done easily on this component allocation operation wise
rgds
gscHello GSC, (and of course anyone able to help me)
taking account of the date of the message (2008) i think you have finally encountered a solution to your issue ?
Well, now i have got the same problem than you before.
My requirement is to modify the component allocation in a routing by using change document.
I found the bapi /SAPMP/BAPI_ROUTING_PROCESS. I have spend few days to make it work without success.
Iam still facing error message. Futhermore i have read trough a SAP note that this BAPI could not work properly in some case.
Considering that Iam trying to study other solutions (BDC ?).
Please, i would appreciate if you give me some advice on this problem.
Thank you very much.
Best regards,
C.S -
Dear all,
I am facing one problem for upload the data from excel to FB01 T-code..
here my excel sheet is like this
Doc Date Posting date Doc type Posting key GL account Amount Posting key GL account Amount
03.04.2010 03.04.2010 40 60011 8391 50 & GL & TAX again repeate....
04.04.2010 04.04.2010 40 60011 5496 40 60012 2198 50 & GL & TAX
05.04.2010 05.04.2010 40 60011 7887 40 60012 0 50 & GL & TAX
How should i do the program.....
plz give me any bapi program or bdc program for this type excel sheet....
plz help me..
Regards
marganiPosting FI documents is one of the more frequently discussed topics here, please search before posting. Do not expect complete solutions for requirements, always work yourself first.
Thread locked.
Thomas -
BDC or BAPI for me01 and me02 please read the requirement below
Hi Experts
I am having one requirement ,that
I need to write a BDC program for Source list
My alt file is having 3 filed with
matnr werks lifnr
if the material no and werks are same and the lifnr is not existing then it has to add the new vendor with the material and werks to the source list
if matnr werks and lifnr are not existing then need to create a new source list
flat file
10000001 4200 0230000000
10000001 4200 0230000000
10000001 4200 0230000000
10000001 4200 0230000001
10000002 4210 0230000002
see in this flat file I'm having two diffrent vendors
suppose in eord table existing
matnr , werks,lifnr
10000001 4200 0230000000
so nw it has to check for whether vendor is existing or not if existing nothing to do if not then it has to add the new vendor
if matnr werks and lifnr or not existing then it has to create new source list
means create the vendor
Is there any BAPI or any sample prog is thr please provide me
WILL GIVE YOU POINTS IMMEDIATELY
Thanks in advanceHi
You can search in SDN for regarding Table Control and also go through the below links:
Here are some of the links
Re: Handling The Table Control while working with BDC
Re: how do we handle BDC table control
Re: how to create bdc with table control
Regards,
Vishwa. -
BAPI or FM or Standard BDC program for Production version creation (C223)
Hi All,
Is there BAPI or FM or Standard BDC program for Production version creation? Please help me.
Thanks & Regards
SanthoshHi,
Try this FM "CO_OCM_CREATE_PROD_VERSION"
Regards,
Smart -
Problem in creating a BDC program for transaction cj20n(project sytem)
Hi all,
I am trying to create project,WBS element ,network and activity using a BDC program,
I am able to create to a recording for the transaction cj20n using tcode shdb but when i run the recording it doesnt run properly i am not able to create any thing.
I get error saying that a particular field doesnt exist on the screen.
Is possible to create a BDC program for transaction CJ20N ?
Also is there any other alternative apart from using a BAPI or a function module.
Thanks,
NishantHi,
Check below link for BAPIs of transaction cj20n.
[BAPI for cj20n|BAPI for CJ20N transaction]
Thanks,
Asit Purbey. -
Bapi for vendor non po invoice parking
Hello,
We have a requirement to Create a Non PO Invoice and also parking invoice.
I could able to create Vendor Invoice (Non PO) using BAPI: BAPI_ACC_DOCUMENT_POST.
But i am unable to find a BAPI for Parking the Vendor Invoice (Non PO). When i try to use BDC on FB01 transaction for creating Parking Vendor Invoice, it is throwing an error that "Parking Invoice creation is not allowed in batch input".
Can anybody help me for creating Parking Invoice (Non PO).
Note: There is a BAPI: BAPI_INCOMINGINVOICE_PARK, which wont support for Non PO Invoice creation. It is PO based.
Thanks in Advance for your support.
Thanks & Regards,
Sreedhar.Hi,
Please see the given link, hope It will help you.
Re: BAPI to Park the Invoice Document
Regards,
Shamma -
BAPI for ABZU - Asset Write UP
Hi
I need to post asset write up documents through ABZU tcode. Can any one help me out with the appropriate BAPI for the same.
BDC will not solve my problem as the set of screen changes as per the 'Transaction Type'.
Regards,
Sudip Kumar Das.Write up is allowed only to the extent of accumulated depreciation from previous years. You can do write up "ABZU". however the accumulated depriciation balance has to carry forward from last fiscal year to current fiscal year and you can do writeup only upto the accumulated depr from the previous yr
-
BAPI for Free Goods determination
Hi Folks,
Can anybody help me providing the BAPI for "Free Goods determination" in MM.
I checked the BAPI_FREEGOODS_CONDITIONS; but I would like to know the BAPI which triggers the free goods determination while creating PO.
For eg I hv condition records in MBN1 and it triggers free goods in PO.
Points for sure
ThanksHi
check the BAPIs
BAPI_FREEGOODS_CONDITIONS
CND_FREEGOODS_CALL_BAPI
CND_FREEGOODS_DEL_AFTER_INIT
CND_FREEGOODS_MAP_BAPIMTCS
if doesn't serve the purpose do it by BDC method
Regards
Anji -
BAPI for Creation of inspection lot
I have two scenario:-
1.Can any body help to find BAPI for creation of Inspection lot for the material under PO envisaged for PDI.
2. Can any body find me a BAPI or FM which can creates inspection lot in QALS table without inspection lot origin under 01 i.e. 0101 or Z01SI01.
My objective is to creation inspection lot without assigning Inspection type of Z01SI01 or Z01SI02 and so on in the material code under a respective Plant 1004 or 1005 0r 1006 so on.
In my Z Development for creation of inspection lot BDC is run for QA01 as this code created inspection lot on when material code has inspection type Z01SI01 i.e. location of source inspection and vendr code particular classification under 010 vendor class inspection type Z01SI01. System search both the inspection type for both material and vendor then create inspection lot in QALS table by assiging inspection matching inspection on the lot.
I want to get rid of assignment of inspection on the materilal. If any BAPI or FM is avalable for creation of inspection without assigning inspection type on material code. I want to create inspection lot in which Inpsection type assignment can be done based on vendor class only.
YPB2. Can any body find me a BAPI or FM which can creates inspection lot in QALS table without inspection lot origin under 01 i.e. 0101 or Z01SI01.
I am very sure that this is not possible.You can not create inspection lot without inspection lot origin or inspection type.
Regards
Sujit -
hi all.. can anyone pls tell me bapi for creating FREE GOODS.. t-code is vbn1..
thanks..Hi
check the BAPIs
BAPI_FREEGOODS_CONDITIONS
CND_FREEGOODS_CALL_BAPI
CND_FREEGOODS_DEL_AFTER_INIT
CND_FREEGOODS_MAP_BAPIMTCS
if doesn't serve the purpose do it by BDC method
Regards
Anji -
Reg bapi for creation of purchase order
hai to all,
i have to upload purchase orders from legacy file to R/3 system
certain order having more than 50 line items
so please any one send me <b>stardard bapi program or bdc program for me21n</b> transaction which will suitable for my senario.
please send asap
regards
vijayhai
i am trying to create po using bapi
the following code explains
constants : c_x value 'X'.
data: del_date type sy-datum.
data: pohead type bapimepoheader.
data: poheadx type bapimepoheaderx.
data: exp_head type bapimepoheader.
data: t_return_out type table of bapiret2 with header line,
wa_return_out TYPE bapiret2.
data: poitem type table of bapimepoitem with header line.
data: poitemx type table of bapimepoitemx with header line.
data: posched type table of bapimeposchedule with header line.
data: poschedx type table of bapimeposchedulx with header line.
data: ex_po_number type bapimepoheader-po_number.
Header Level Data
pohead-comp_code = '1011'.
pohead-doc_type = 'NB' .
pohead-creat_date = sy-datum .
pohead-vendor = 'A1138'.
pohead-purch_org = 'DOMS'.
pohead-pur_group = 'MFR'.
pohead-langu = sy-langu .
pohead-doc_date = sy-datum.
poheadx-comp_code = c_x.
poheadx-doc_type = c_x.
poheadx-creat_date = c_x.
poheadx-vendor = c_x.
poheadx-langu = c_x.
poheadx-purch_org = c_x.
poheadx-pur_group = c_x.
poheadx-doc_date = c_x.
Item Level Data
poitem-po_item = 1.
poitem-material = '000000000100001079'.
poitem-plant = 'HO01'.
poitem-stge_loc = ''.
poitem-quantity = 1.
append poitem.
poitemx-po_item = 1.
poitemx-po_itemx = c_x.
poitemx-material = c_x.
poitemx-plant = c_x .
poitemx-stge_loc = c_x .
poitemx-quantity = c_x .
poitemx-tax_code = c_x .
poitemx-item_cat = c_x .
poitemx-acctasscat = c_x .
append poitemx.
Schedule Line Level Data
posched-po_item = 1.
posched-sched_line = 1.
posched-del_datcat_ext = 'D'.
del_date = sy-datum + 1.
write del_date to posched-delivery_date.
posched-deliv_time = '000001'.
posched-quantity = 1.
append posched.
poschedx-po_item = 1.
poschedx-sched_line = 1.
poschedx-po_itemx = c_x.
poschedx-sched_linex = c_x.
poschedx-del_datcat_ext = c_x.
poschedx-delivery_date = c_x.
poschedx-quantity = c_x.
append poschedx.
call function 'BAPI_PO_CREATE1'
EXPORTING
poheader = pohead
poheaderx = poheadx
testrun = ' '
IMPORTING
exppurchaseorder = ex_po_number
expheader = exp_head
TABLES
return = t_return_out
poitem = poitem
poitemx = poitemx.
poschedule = posched
poschedulex = poschedx.
call function 'BAPI_TRANSACTION_COMMIT'
EXPORTING
wait = 'X'.
if not ex_po_number is initial.
call function 'DEQUEUE_ALL'.
else.
call function 'DEQUEUE_ALL'.
message i036.
endif.
**endform. " create_po
IF ex_po_number IS NOT INITIAL.
CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'.
PERFORM show_result.
ELSE.
CALL FUNCTION 'BAPI_TRANSACTION_ROLLBACK'.
PERFORM show_result.
ENDIF.
*& Form show_result
text
--> p1 text
<-- p2 text
FORM show_result .
LOOP AT t_return_out INTO wa_return_out.
write : ex_po_number.
WRITE : / wa_return_out-type,
/ wa_return_out-id,
/ wa_return_out-number,
/ wa_return_out-message,
/ wa_return_out-log_no,
/ wa_return_out-log_msg_no,
/ wa_return_out-message_v1,
/ wa_return_out-message_v2,
/ wa_return_out-message_v3,
/ wa_return_out-message_v4,
/ wa_return_out-parameter,
/ wa_return_out-row,
/ wa_return_out-field,
/ wa_return_out-system.
ENDLOOP.
<b>iam geting the error such that</b>
E
BAPI
001
No instance of object type PurchaseOrder has been created. External reference:
000000
PurchaseOrder
POHEADER
1
E
ME
062
Account assignment mandatory for material 100001079 (enter acc. ***. cat.)
000000
100001079
POITEM
<b>how to correct this error</b>
regards
vijay -
Bapi for creation of equipment master
hi friends ,
I have to made a BDC program for creation of equipment master .
for that I am using bapi i.e. ' BAPI_EQUI_CREATE '.
I had matched the fields of transaction IE01 but in the additinal data part i could not able to map 'Partner' fields .
pls some body can guide what should i do for it.Hi Das,
If u r going to create equipment no against this Bapi BAPI_EQUI_CREATE"
then u need to pass material no, Equipment type, Serial No. there is no need to give partner no .
If its good, then plz give point.
Maybe you are looking for
-
Calendar duplicates not showing up in ical/snow leopard
After upgrading to ios5 and activating icloud, my ical entries on my macbook duplicated (as did the calendar entries on my iphone and ipad). I cleaned the macbook duplicates with spanning tools, resulting in an ical file on my macbook that is withou
-
Having Problems Downloading Photoshop for Creative Cloud
Hi all, I just bought Photoshop CC 2015. I used the annual pre-paid method. I think something got messed up. I bought the program. I received the confirmation E-mail. I clicked on 'Download' on the Photoshop app located on the Desktop on this site. O
-
I need some sort of a Timer ..
How are you doing ... I'm making a game for my gr 12 class, Target Practice crap, very simple. I don't know how to get the target to stay up for a certain amount of time, and then dissapear at a next random spot, OR dissapear if it's clicked on ... i
-
Unable to install Moutain lion from Recovery Parition
Hi Folks, Well running into some issues with my iMac. (27" i5, 1TB drive) Problem started when my two year old forced 2 CD's into the DVD bay. DVD was not happy and was making this horrible grinding noise. Went to Apple store which is 3 Hours away, t
-
Inconsistent compression with Deflater/Inflater
I try to (un)compress some data using the (In)Deflater class. I want to have GZIP compression, so I set nowrap to true. The javadoc for the Inflater class says something mysterious like "Note: When using the 'nowrap' option it is also necessary to pr