how to create bdc for sales order ? if any one kow the
steps plz mail me at toamitshri@gmail.com
Answers were Sorted based on User's Feedback
Answer / bandivenkateswarlu
This is done by using the some process steps:
These steps are given below. and go through that steps.
1. Analyze the data from the local file or flat file.
2. Analyze the transaction.
3. Declaring the internal table (BDCDATA)
program: name of the module pool program name
dynpro: screen number.
dynbegin: it indicates for the new screen.
fname: name of the fields in the screen
fval : the values are assigned with the fields.
4.Transferring the data from the local file to internal table
5. Populating the internal table.
Is This Answer Correct ? | 2 Yes | 2 No |
Answer / david carragher
USe IDOC_INPUT_ORDERS as mapping. The standard IDOC uses
BDC for posting, details will be found in the function
module.
Is This Answer Correct ? | 1 Yes | 1 No |
report ZTEST_BDC_MA
no standard page heading line-size 255.
*DATA: ld_file LIKE rlgrap-filename.
DATA: gd_file type string.
*Internal tabe to store upload data
TYPES: BEGIN OF t_record,
AUART LIKE VBAK-AUART,
VKORG LIKE VBAK-VKORG,
VTWEG LIKE VBAK-VTWEG,
SPART LIKE VBAK-SPART,
KUNNR LIKE KUAGV-KUNNR,
KUNNR1 LIKE KUAGV-KUNNR,
MATNR LIKE MARA-MATNR,
PRCTR LIKE COBL-PRCTR,
END OF t_record.
DATA: it_record TYPE STANDARD TABLE OF t_record INITIAL
SIZE 0,
wa_record TYPE t_record.
*Text version of data table
TYPES: BEGIN OF t_uploadtxt,
AUART LIKE VBAK-AUART,
VKORG LIKE VBAK-VKORG,
VTWEG LIKE VBAK-VTWEG,
SPART LIKE VBAK-SPART,
KUNNR LIKE KUAGV-KUNNR,
KUNNR1 LIKE KUAGV-KUNNR,
MATNR LIKE MARA-MATNR,
PRCTR LIKE COBL-PRCTR,
END OF t_uploadtxt.
*Used to store BDC data
DATA: BEGIN OF bdc_tab OCCURS 0.
INCLUDE STRUCTURE bdcdata.
DATA: END OF bdc_tab.
*Used to stores error information from CALL TRANSACTION
Function Module
*DATA: BEGIN OF messtab OCCURS 0.
* INCLUDE STRUCTURE bdcmsgcoll.
*DATA: END OF messtab.
gd_file = ' Your workstation file name'.
CALL FUNCTION 'GUI_UPLOAD'
EXPORTING
filename = gd_file
has_field_separator = 'X' "file is TAB delimited
TABLES
data_tab = it_record
EXCEPTIONS
file_open_error = 1
file_read_error = 2
no_batch = 3
gui_refuse_filetransfer = 4
invalid_type = 5
no_authority = 6
unknown_error = 7
bad_data_format = 8
header_not_allowed = 9
separator_not_allowed = 10
header_too_long = 11
unknown_dp_error = 12
access_denied = 13
dp_out_of_memory = 14
disk_full = 15
dp_timeout = 16
OTHERS = 17.
IF sy-subrc NE 0.
write: 'Error ', sy-subrc, 'returned from GUI_UPLOAD
FM'.
skip.
endif.
include bdcrecx1.
start-of-selection.
perform open_group.
Loop at it_record into wa_record.
perform bdc_dynpro using 'SAPMV45A' '0101'.
perform bdc_field using 'VBAK-AUART'
wa_record-auart.
perform bdc_field using 'VBAK-VKORG'
wa_record-vkorg.
perform bdc_field using 'VBAK-VTWEG'
wa_record-vtweg.
perform bdc_field using 'VBAK-SPART'
wa_record-spart.
perform bdc_dynpro using 'SAPMV45A' '4001'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_field using 'KUAGV-KUNNR'
wa_record-kunnr.
perform bdc_field using 'KUWEV-KUNNR'
wa_record-kunnr1.
perform bdc_field using 'BDC_CURSOR'
'RV45A-KWMENG(01)'.
perform bdc_field using 'RV45A-MABNR(01)'
wa_record-matnr.
perform bdc_field using 'RV45A-KWMENG(01)'
' 1'.
perform bdc_dynpro using 'SAPMV45A' '4001'.
perform bdc_field using 'BDC_OKCODE'
'=ITEM'.
perform bdc_field using 'KUAGV-KUNNR'
wa_record-kunnr.
perform bdc_field using 'KUWEV-KUNNR'
wa_record-kunnr1.
perform bdc_field using 'BDC_CURSOR'
'RV45A-MABNR(01)'.
perform bdc_dynpro using 'SAPMV45A' '4003'.
perform bdc_field using 'BDC_OKCODE'
'=T\07'.
perform bdc_field using 'BDC_CURSOR'
'RV45A-KWMENG'.
perform bdc_field using 'RV45A-KWMENG'
' 1,000'.
perform bdc_field using 'VBAP-VRKME'
'TA'.
perform bdc_field using 'RV45A-ETDAT'
'10.04.2010'.
perform bdc_field using 'RV45A-PRGBZ'
'D'.
perform bdc_field using 'VBKD-PRSDT'
'10.04.2010'.
perform bdc_dynpro using 'SAPMV45A' '4003'.
perform bdc_field using 'BDC_OKCODE'
'=T\06'.
perform bdc_field using 'BDC_CURSOR'
'VBAP-ABGRS'.
perform bdc_field using 'DKACB-FMORE'
'X'.
perform bdc_dynpro using 'SAPLKACB' '0002'.
perform bdc_field using 'BDC_CURSOR'
'COBL-PRCTR'.
perform bdc_field using 'BDC_OKCODE'
'=ENTE'.
perform bdc_field using 'COBL-PRCTR'
wa_record-prctr.
perform bdc_dynpro using 'SAPMV45A' '5003'.
perform bdc_field using 'BDC_OKCODE'
'/EBACK'.
perform bdc_field using 'BDC_CURSOR'
'KOMV-KSCHL(07)'.
perform bdc_dynpro using 'SAPMV45A' '4001'.
perform bdc_field using 'BDC_OKCODE'
'=SICH'.
perform bdc_field using 'KUAGV-KUNNR'
wa_record-kunnr.
perform bdc_field using 'KUWEV-KUNNR'
wa_record-kunnr1.
perform bdc_field using 'BDC_CURSOR'
'RV45A-MABNR(02)'.
perform bdc_transaction using 'VA01'.
endloop.
perform close_group.
Is This Answer Correct ? | 0 Yes | 4 No |
In table maintenance generator, how to restrict the values that has to be shown for one field for a particular user ?
Lock objects and what are parameters of ENQUEUE FM?
Explain pai and pbo.
Hi, I am a Trainer in SAP ABAP having 2 years of experience in teaching ABAP and having 5 years of real time work experience in industry. If any body is interested email me your contact details to sap.abap9@gmail.com I will provide online training. Excellent material is provided. If any one is interested for training you can contact me for further details. Free demo is provided before joining the course. Excellent Training for reasonable price. SD and MM Concepts will be teached freely. References will be provided upon request.
what are userexits?? how to use it?? whats the importance of them?? can it be used in interactive reporting to directly come to basic list??
Can ‘where’ clause be used when updating database entries?
What is direct input method ?
What are domains and data element?
What does nw 7.4 sp 05/nw 7.5 sp 02 offers in abap?
What is a matchcode?
What happens when a table is activated in DD?
Can a transparent table exist in data dictionary but not in the data base physically? : sap abap data dictionary