Billng document creation using bdc
hi experts,
I've been using bapi for sales order and outbound delivery creation. But for billing document i'm using BDC. it's simpler. The creation of sales order and outbound delivery has no problem. The problem is upon creation of the billing document, it only creates the last entry in the item level. Example, if item has 10,20, and 30; it will only create item 30 in the billing document level. But no problem with the sales order and outdel. What could i be missing here?
Thank you in advance!
Hi,
Im actually not very particular on where in the bdc code the line items are being processed. the only variable that I see here is the outbound del number which is g_odnum. Here is the BDC code.
f_bdc_dynpro 'SAPMV60A' '0102'.
f_bdc_field 'BDC_CURSOR' 'KOMFK-VBELN(01)'.
f_bdc_field 'BDC_OKCODE' '/00'.
f_bdc_field 'KOMFK-VBELN(01)' g_odnum.
f_bdc_dynpro 'SAPMV60A' '0104'.
f_bdc_field 'BDC_CURSOR' 'VBRK-FKART'.
f_bdc_field 'BDC_OKCODE' '=SICH'.
f_bdc_transaction 'VF01'.
Can you help me identify where it is in this BDC code?
Thanks for you help!
Similar Messages
-
Material Creation Using BDCs.
Hi all,
I have developed a program for Material Creation using BDC.
Material is Being created and that is working well and good.Here i have a Requirement to update the Newly creted material in Ztable.So when i use call transaction mathod,i have written code for updation under the line CALL TRANSACTION.where in iam getting newly creatde material from MARA table,and so it is working perfectly fine..
But our requirement should be sessions method,so when i use sessions method and exeute the program..we face the problem of updation.
the piece of code for updation is updating previously created material.
Literally speaking only the sessions are created ,when the program is executed,material is not created when program is run.Material is only created when the sessions are processed using SM35,
So how should i do here,where should be the updation code written and where will we get the newly created material in sessions method..
Pls Help me in solving this problemhai priyanaka it might be due to configuration problem
bcos manulay also ur gettign this , so just consult ur MM consultant for soem setting
regards
afzal -
Upload data for Tcode LT06(Transfer order creation) using BDC -very urgent
hi experts,
I got stucked up in writing a BDC for the Tcode LT06(Transfer order creation using wearhouse number) in MM module,
the problem is like this, when i go to the tcode LT06 , it will ask for material doucument,mat. docu. year and wearhouse number, iam entering the inputs and then press enter, as soon as i press enter it takes me to the second screen where i will be selecting the item and then click on the button called 'Generate TO item'
here the problem arises, as soon as i click the button iam getting a standard SAP error message(No Destination Storage Bin found in storage type 'IMP'). Due to this errror iam not able populate the batch input data on the screen, suggest me a proper solution. rewards will given if solution found useful.
Kishore KHi ,
I have done the same in Background with BDC and TR Number for Multiple Materials ,
Can u please explain the scenario, so then I would be able to try for solution ?
Warm Regards. -
Error in Accounting document Posting using - BDC
While creatind document in FB01 using BDC
PERFORM fill_dynpro_fields1 USING:
co_true co_program '0100' lit_bdcdata,
space 'BKPF-BLDAT' it_bkpf-bldat lit_bdcdata,
space 'BKPF-BUDAT' it_bkpf-budat lit_bdcdata,
space 'BKPF-BLART' tp_type1 lit_bdcdata,
space 'BKPF-BUKRS' it_bkpf-bukrs lit_bdcdata,
space 'BKPF-WAERS' it_bkpf-waers lit_bdcdata,
space 'BKPF-XBLNR' it_bkpf-xblnr lit_bdcdata,
space 'RF05A-NEWBS' lco_postkey lit_bdcdata,
space 'RF05A-NEWKO' it_bseg-kunnr lit_bdcdata,
space 'BDC_OKCODE' co_intro lit_bdcdata,
co_true co_program '0301' lit_bdcdata,
space 'BSEG-WRBTR' it_bseg-wrbtr lit_bdcdata,
space 'BSEG-ZTERM' it_bseg-zterm lit_bdcdata,
space 'BSEG-SGTXT' it_bseg-sgtxt lit_bdcdata,
space 'RF05A-NEWBS' lco_postkey1 lit_bdcdata,
space 'RF05A-NEWKO' it_bseg-kunnr lit_bdcdata,
space 'BDC_OKCODE' co_intro lit_bdcdata,
co_true co_program '0301' lit_bdcdata,
space 'BSEG-WRBTR' it_bseg-wrbtr lit_bdcdata,
space 'BSEG-ZTERM' it_bseg-zterm lit_bdcdata,
space 'BSEG-SGTXT' it_bseg-sgtxt lit_bdcdata,
space 'BDC_OKCODE' co_intro lit_bdcdata.
I am getting message like bseg-wrbtr input value is longer than screen field. but i have declare it as same type as above space 'BSEG-WRBTR' it_bseg-wrbtr lit_bdcdata,
Can you help me.
Always use proper subject lineHi Vijay ,
I have one more problem regarding same please help me.
In the program i am calling the transaction FB01 twice and two different document is created of SA and DA type.
After the program is executed i can only see the DA document created log message. But the SA document(message) is getting suppressed but the document is getting created .
How can i get the both document no at a time once i run the program. -
Delivery Document creation using buffered data?
We're using BAPIs to create an STO with estimated volumes/dates.
But, when the Actual information comes in, we first update the STO with actual volume, then create a delivery document. The problem is that the delivery document is using the estimated volume even though we've committed the volume change and can pull up the STO to see it prior to Delivery create.
For STO, we're using:
BAPI_PO_CREATE1 and
BAPI_PO_CHANGE
For Delivery creation, we're using:
BAPI_OUTB_DELIVERY_CREATE_STO
It seems that the Delivery is reading buffered information rather than what's actually been committed to the DB. Is there a way to bypass the buffer when calling this BAPI?
thanks,
RobertFound a note that has addressed the issue
2008537 - Short dump while changing a replenishment delivery multiple times in one transaction -
Contract creation using BDC wherein Net order price is Zero
Hi,
Please let me know the solution to the above problem.
I am trying to create a quantity contract using BDC but the Net Order Price is coming as Zero even though the condition type PB00 is maintained properly in the info record with some net order price which is not equal to zero.
Please let me know asap as this is a critical issue. The same problem is not happening if i try an create a contract manually.Hi,
Please let me know the solution to the above problem.
I am trying to create a quantity contract using BDC but the Net Order Price is coming as Zero even though the condition type PB00 is maintained properly in the info record with some net order price which is not equal to zero.
Please let me know asap as this is a critical issue. The same problem is not happening if i try an create a contract manually. -
Delivery document creation using vl01n
Hi,
I want to create a delivery document using VL01n.i need to create the doc for a particular selected item if there are many items for the order.i want to delete the remaining documents.
how to handle this in BDC.just mention along with order ...
from item
as well as
to item fields .... -
XML document creation using reflection
Hi all,
I'm tyring to write a class which creates an XML document from objects passed in. For example, you call the add(Object) method and it takes your object, uses reflection, then outputs XML like this...
<fieldName>fieldValue<fieldName>
The only problem is that after looking through this forum I am a little concerned about the performance of my proposed solution (using reflection).
The class will be used in a batch process which processes millions of objects (to generate a whopping XML file that'll be sent on for further processing by a third party).
Is there a better way to do this than by using reflection?
This class is going to be used by multiple batch processes hence there will be lots of different object types passed (they'll also be new ones in the future that we don't even know about yet) hence my reflection choice.
Thanks,
ChrisThe only problem is that after looking through this
forum I am a little concerned about the performance of
my proposed solution (using reflection).The only way that you'll know for sure is if you try it out. Write the code, test it, then run it in a profiler to find out where the performance problems (if any) are.
Is there a better way to do this than by using
reflection?Probably not, if you want to pass any arbitrary object to it.
One possible alternative is to have "XML aware" objects: define an interface WritesXML, that defines a method toXML(). You then check to see whether the given object implements this interface, and if it does you simply call the method, otherwise you use reflection.
Another alternative, assuming that your objects follow the Bean pattern, is to create "XML-ifiers" on the fly, similar to the way an app-server handles JSPs. First time you see an object you create a class that will write it to XML, then compile this class and invoke it for all subsequent objects. This will require that you have a JDK installed on the runtime machine, that the objects follow the Bean pattern, and that the number of instances of a given class are very high.
This class is going to be used by multiple batch
processes hence there will be lots of different object
types passed (they'll also be new ones in the future
that we don't even know about yet) hence my reflection
choice.Sounds like a good reason to use reflection. -
Sales document creation using bapi
Hi Experts ,
When i try create sales order using bapi " BAPI_SALESDOCU_CREATEFROMDATA'" , it says error like this , Please enter sold to party and ship to party, even though we are sending partner number it shows same error , if we pass values directly in se37 we get the correct result , but when we are calling it in program it says error.
Error on this field : partner Number
Thanks & Regards
Siva KrishnaHi shiva,
Please go through the documentation,
Sales document type is checked with sales and distribtion document type.
You must at least enter order header data (using the structure ORDER_HEADER_IN) and partner data (using the table ORDER_PARTNERS).
Furthermore, you must enter the business object for which the sales document is to be created:
- BUS2030 for inquiries
- BUS2031 for quotations
- BUS2032 for sales orders
I think ur program,
does not pass business object , kindly check -
Hi All,
I have a requirement as described below.
while creating a sales order, if u go to header level and then partners tab in that, u would see a table like structure where u have sold-to-party, ship to party, bill to party, and payer.
My requirement is that i need to select ship-to-party and press details button then i want to change the details there.everything is working fine at the moment.
but i have a doubt that the order of ship to party, sold to party , payer and bill-to-party wouldnt be same all the time.now the ship-to-party is in 4th position.so, in BDC recording it is GVS_TC_DATA-SELKZ(04), i am setiing that to 'X' and iam going ahead.what if the position changes?
is there anyway that i can trace the ship-to-party position whether it is in position 1 or 2 or 3 or 4.
could some one help me with this.
Thanks in advance,
sureshUse the function module VIEW_KUAGV. Pass soldto details and document details being created in inport parameter comwa and pass shipto number in WE_INPUT and fif_no_dialog = 'X',no_address_data = 'X'.
This gives the exact structure of how the partners will appear when you create a sales order in table xvbpa. You can find the positions of partners from the table.
Award points if answer is helpfull. -
Creation of Material using BDC Session method & global class
Hi
Creation of Material using BDC Session method & global class by using oops.
can anyone plz help me outHi,
it looks like it's not possible to call this BAPI wihtout material number. Here is a quote from BAPI documentation.
When creating material master data, you must transfer the material
number, the material type, and the industry sector to the method. You
must also enter a material description and its language.
Cheers -
TSW-Ticket Creation & Actualization using BDC
Hi,
I am using BDC for Ticket creation using transaction O4TEN.
After execution of this BDC, Ticket get created and Saved but it does not actualize ticket even if we click actualize button using BDC.
In real scenario, after ticket creation the status and substatus values should be "C"(Planned) and "6" (Complete) but in this case the status and substatus values are "B"(Checked) and "4"(Positive).
If we create ticket directly using O4TEN then it actualizes ticket properly.
I am not able to find out why BDC is not actualizing tickets.
Any idea?
Regards,
UmeshHi,
I tried BDC for SAVE but still not getting Ticket Key.
So now I am using FM: OIJ_EL_A_TICKETS_MAINTAIN_N.
It creates ticket but in Ticket Item table Ticket item field is blank. Purpose is blank.
Also OIJ_EL_TKT_I_O1 and OIJ_EL_TKT_I_O2 are not populated.
In header I am passing: TICKET_PURPOSE, TICKET_TYPE, UPDKZ = 'I'
and In item I am passing: NOMNR, NOMTK, NOMIT, MENGE, MEINS, TIME_ST_LOAD_STA, TIME_ST_LOAD_END, BUDAT UPDKZ = 'I'.
am I missing something?
Code is as follows:
Replace BDC with function module: OIJ_EL_A_TICKETS_MAINTAIN_N
1) Call FM: OIJ_EL_A_TICKETS_MAINTAIN_N
2) Call FM: ENQUEUE_E_OIJTKT
3) Call FM: OIJB_GENERATE_DOCUMENTS_N
4) Call FM: DEQUEUE_E_OIJTKT
DATA: ls_tkt_h TYPE roij_el_ticket_hvb,
ls_tkt_i TYPE roij_el_ticket_i_io,
ls_oijnomi TYPE oijnomi,
ls_roijnomiio TYPE roijnomiio,
ls_ticket_item TYPE oij_el_ticket_i,
ls_ticket_item_o1 TYPE oij_el_tkt_i_o1,
ls_ticket_item_o2 TYPE oij_el_tkt_i_o2,
ls_ticket_header_pv TYPE oij_el_ticket_h,
ls_ticket_header TYPE oij_el_ticket_h,
ls_tkt_i_o1 TYPE oij_el_tkt_i_o1,
ls_tkt_i_o2 TYPE oij_el_tkt_i_o2.
DATA: lv_time TYPE sy-uzeit.
DATA: it_tkt_i TYPE roij_el_ticket_i_io_t,
it_tkt_h_evt TYPE roijte_t,
it_tkt_h_evt_txt TYPE oij_txt,
it_tkt_i_evt TYPE roijte_t,
it_tkt_i_evt_txt TYPE oij_txt,
it_tkt_i_o1 TYPE roij_el_tkt_i_o1_t,
it_tkt_i_o2 TYPE roij_el_tkt_i_o2_t,
it_tkt_err_log TYPE oij_el_err_log_tt,
it_tkt_doc_flow TYPE roij_el_doc_flow_io_t,
it_return TYPE bapiret2_t,
it_oijnomh TYPE oijnomh_t,
it_oijnomi TYPE oijnomi_t,
it_ticket_item TYPE STANDARD TABLE OF oij_el_ticket_i,
it_ticket_item_o1 TYPE STANDARD TABLE OF oij_el_tkt_i_o1,
it_ticket_item_o2 TYPE STANDARD TABLE OF oij_el_tkt_i_o2.
ls_tkt_h-ticket_purpose = '1'.
ls_tkt_h-ticket_type = lv_ticket_type.
IF lv_ticket_type EQ c_yp2.
If Ticket type is YP2 then
ls_tkt_h-yy_mct_cat = fp_mct_cat.
ENDIF.
ls_tkt_h-yy_pat_alc = lv_alloc_rule.
ls_tkt_h-updkz = 'I'.
ls_tkt_i-nomnr = fp_s_tc1-nomnr.
ls_tkt_i-nomtk = fp_s_tc1-nomtk.
ls_tkt_i-nomit = fp_s_tc1-nomit.
ls_tkt_i-menge = lv_menge.
ls_tkt_i-meins = fp_s_tc1-units.
CLEAR ls_oijnomi.
SELECT SINGLE * FROM oijnomi INTO ls_oijnomi
WHERE nomtk = fp_s_tc1-nomtk
AND nomit = fp_s_tc1-nomit.
IF sy-subrc EQ 0.
MOVE-CORRESPONDING ls_oijnomi TO ls_roijnomiio.
ENDIF.
PERFORM get_timestamp USING fp_sdate
lv_time
ls_roijnomiio
CHANGING ls_tkt_i-time_st_load_sta.
PERFORM get_timestamp USING fp_edate
lv_time
ls_roijnomiio
CHANGING ls_tkt_i-time_st_load_end.
CONCATENATE lv_budat(4) lv_budat5(2) lv_budat8(2) INTO ls_tkt_i-budat.
ls_tkt_i-updkz = 'I'.
APPEND ls_tkt_i TO it_tkt_i.
CALL FUNCTION 'OIJ_EL_A_TICKETS_MAINTAIN_N'
EXPORTING
is_tkt_header = ls_tkt_h
IT_HEADER_EVT =
IT_HEADER_EVT_TXT =
it_items = it_tkt_i
IT_ITM_EVT =
IT_ITM_EVT_TXT =
IT_ITM_O1 =
IT_ITM_O2 =
IT_TKT_ERROR_LOG =
it_tkt_doc_flow = it_tkt_doc_flow
iv_commit = 'X'
IV_LOCK =
IV_ADD_TO_LOG =
IV_CALL_TO_OUTPUT =
IMPORTING
es_tkt_header = ls_tkt_h
ET_HEADER_EVT = it_tkt_h_evt
ET_HEADER_EVT_TXT = it_tkt_h_evt_txt
et_items = it_tkt_i
ET_ITM_EVT = it_tkt_i_evt
ET_ITM_EVT_TXT = it_tkt_i_evt_txt
et_itm_o1 = it_tkt_i_o1
et_itm_o2 = it_tkt_i_o2
ET_TKT_ERROR_LOG = it_tkt_err_log
et_tkt_doc_flow = it_tkt_doc_flow
et_return = it_return
EXCEPTIONS
ticket_locked = 1
OTHERS = 2
IF sy-subrc NE 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ELSE.
COMMIT WORK AND WAIT.
Lock the ticket
There is no check neccessary if the ticket has already
been locked by an other user because it has just been
created.
CALL FUNCTION 'ENQUEUE_E_OIJTKT'
EXPORTING
mode_oij_el_ticket_h = 'E'
mandt = sy-mandt
ticket_key = ls_tkt_h-ticket_key
ticket_version = ls_tkt_h-ticket_version
ticket_purpose = ls_tkt_h-ticket_purpose
EXCEPTIONS
foreign_lock = 1
system_failure = 2
OTHERS = 3.
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ENDIF.
CALL FUNCTION 'OIJB_GET_NOMINATION_DATA'
EXPORTING
ACTIVITY =
is_ticket_header = ls_tkt_h
is_ticket_item = ls_tkt_i
IV_ADD_TO_LOG =
CHANGING
ct_oijnomh = it_oijnomh
ct_oijnomi = it_oijnomi
RETURN =
EXCEPTIONS
ticket_data_error = 1
no_nomination_selected = 2
OTHERS = 3
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ls_ticket_header = ls_tkt_h.
LOOP AT it_tkt_i INTO ls_tkt_i.
MOVE-CORRESPONDING ls_tkt_i TO ls_ticket_item.
APPEND ls_ticket_item TO it_ticket_item.
ENDLOOP.
LOOP AT it_tkt_i_o1 INTO ls_tkt_i_o1.
MOVE-CORRESPONDING ls_tkt_i_o1 TO ls_ticket_item_o1.
APPEND ls_ticket_item_o1 TO it_ticket_item_o1.
ENDLOOP.
LOOP AT it_tkt_i_o2 INTO ls_tkt_i_o2.
MOVE-CORRESPONDING ls_tkt_i_o2 TO ls_ticket_item_o2.
APPEND ls_ticket_item_o2 TO it_ticket_item_o2.
ENDLOOP.
CALL FUNCTION 'OIJB_GENERATE_DOCUMENTS_N'
EXPORTING
i_ticket_header = ls_ticket_header
i_ticket_header_pv = ls_ticket_header_pv
I_CLOSE_SHIPMENT = ' '
TABLES
t_ticket_item = it_ticket_item
t_ticket_item_o1 = it_ticket_item_o1
t_ticket_item_o2 = it_ticket_item_o2
T_TICKET_ITEM_PV =
T_TICKET_ITEM_O1_PV =
T_TICKET_ITEM_O2_PV =
t_oijnomh = it_oijnomh
t_oijnomi = it_oijnomi
T_DOC_FLOW =
T_ERR_LOG =
T_REVERSAL_DOCS =
T_ORIGINAL_DOCS =
T_TICKET_SUBITEM =
EXCEPTIONS
error_during_cip_process = 1
error_during_checks = 2
nomination_lock_error = 3
nomination_read_error = 4
cip_process_read_error = 5
OTHERS = 6
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ELSE.
COMMIT WORK AND WAIT.
ENDIF. -
Capture document no after saving a set of data using BDC
Hi All,
Can u give a useful solution for caputuring data in a transaction.the scenario is:-
1.an excel sheet data should be uploaded in a transaction O3URV_SS0 using BDC.----
done with call transaction
2.it will save all the line items associated with a particular header data.----
done
3.after save, it will generate a document no automatically for each header.----
[this no is stored in the table OIUVL_SSTH]
4.now I have 2 capture this doc no and print a message.
for step 4 i have tried with GET PARAMETER ID.But I am unable to get the doc no.
can anyone give me the proper solutin and send me the piece of code.
Thanks.Hi Kalpita,
Hope you are handling the messages in your BDC process using the MESSAGES option in the CALL TRANSACTION. If so, after the CALL Transaction, check the Message table each line, most probably the required Doc.No will be avaible in the message as a component for the success message.
Eg. Document XXXXXXXXX created successfuly ( Here XXXXXXXXX is the doc no. available in the message as a variable )
Hope this will help you.
Regards,
Smart Varghese -
How to use Add Shipments functionality in Shipment document creation
Dear All,
We wanted to use the Add Shipments functionality in the Shipment document creation / change.
We have two different shipment types.
I want to add shipments of one shipment type in to Shipment document of anohter shipment type.
I am not able to do it now as system is saying in the selection log that the shipment types are not same.
Please let me know what are the pre requisite configurations to enable us to add shipments in to another shipment.
Please let me tknow he standard functionality of "Add Shipments option" and how to use it to add shipments in a Shipment
Regards
VenkatHi Venkat,
The option "find shipments" is provided to select the shipments to reassign or deassign the deiveries etc in VT01n or VT02n
transaction planning screen. Basically you can play around to assign and reassign the deliveries to different shipments
This option is not creating the shipment within shipment. It is just selection of shipments for planning purposes
Hope this helps.
Regards,
Ramana -
Reg:how to post the parked documents using BDC
Duplicate message in General deleted. Please do not post the same question in more than one forum.
Hi
I am creating parked Documents using FV50. I am able to check them using FBV0, I am able to select and post the documents using the same transaction. Its working fine. However I want to post the selected parked documents using BDC. I am having problems as the output in FBV0 is in ALV report format. HAving problems selcting the parked documents to be posted. As there any way to post the selected parked documents using BDC.
Please suggest me a solution for this.
Thanks,
Satish
Edited by: Matt on Dec 3, 2008 7:40 PMHi Rob,
Thank you for ur reply, can u send that code how u post the parked documents using BDC for FBV0 transaction. Please send the code.
Thanks,
Satish
Maybe you are looking for
-
How do I share edited photos with other apple devices.
Photo Stream does a great job of sharing photos between your mac, your ipad, and your iphone UNTILL you want to edit them. How do I edit a photo and then be able to see the edited version on all my devices? If I edit on my Macbook, the changes are m
-
IO Error while deploying CAF WebDynpro DC
I am trying to deploy a CAF WebDynpro DC and get this error message while deploying with LocalDevelopment (no NWDI): All required pre-development steps for local development of a WebDynpro with GP interface (used DC's, implemented interfaces, WebDynp
-
Splitting large files for upload
I need to upload a very large file to an FTP site, 9.8G. This takes a hugely long time with my bandwidth and invariablly fails somewhere before it finishes. Does anyone know if there is software that will take a large file like this, split it up, per
-
I want to output QT multichannel sound from my Intel Mini and G5 to my stereo while playing back H.264 movie trailers and anything I convert from OTA HDTV broadcasts. I know I need up to 7.1 analog output for QT AAC multichannel and digital spdif pas
-
How do I delete a 'trusted network'?
Somehow I have a 'linksys' as one of my trusted networks and if my own internet isn't hooked up, it will pick up this person's signal. I don't recall ever okaying it (I may have clicked something by accident) and now I can't figure out how to 'untrus