Need upload program for Vendor master partners (XK02)
Hello Experts,
I need to write data uplaod program for XK02 for vendor master Partner functions. ( Basically we created some custom partner functions and attach it to many existing vendors ).
So kindly advice me which is the suitable upload method for this.
1) There is no BAPI available for editing vendors.
2) BDC is not possible because the Vendor partner screen is having table control and some records are already filled. (No of row not fixed).
Is there any IDOC available or any standard input pgm?
Please give suggestion.
Thanks and rgds,
Anand
Hi,
You can use LSMW --> Vendor Master which supports bothe XK01 and XK02.
This is a standard Batch input program (RFBIKR00). Look at this program documentation for more info.
Regards
Sudhir Atluru
Similar Messages
-
Upload program for Vendor master Partner Data in XK02 needed info
Hello Experts,
I need to write data uplaod program for XK02 for vendor master Partner functions. ( Basically we created some custom partner functions and attach it to many existing vendors ).
So kindly advice me which is the suitable upload method for this.
1) There is no BAPI available for editing vendors.
2) BDC is not possible because the Vendor partner screen is having table control and some records are already filled. (No of row not fixed).
Is there any IDOC available or any standard input pgm?
Please give suggestion.
Thanks and rgds,
AnandFor the IDOC perspective, you can uses CREMAS.
For the mass maintenance you still have XK99 (which also uses CREMAS internally)
True there is NO BAPI
For the BDC and the table control. Well this is not really true.
In batchinput, instead of maintaining the rows by there Number, you should select it at the first position.
OK-CODE /06 will open a selection screen SAPMF02K 2324. The result of the selection screen goes to the first line of the table control.
Of course this works only in BDC
reward points if helpful
Edited by: Alain Bacchi on Jun 18, 2008 8:48 AM -
Upload program for vendor master
Hi Friends,
Could you please help me in this.
actually i have a program like this:
i have to download the data from an excel sheet and reformat it and output into a text file so that the data can be uploaded into vendor master using standard progarm
<b>"RFBIKR00".</b>
i have written the program like this:
but in the middle when formatting the data...i'm facing the problem....
plz help me in solving that...
thnx very very much...........
the program i wrote is like this:
<b>
tables: lfa1,
lfb1,
lfm1,
lfbk,
bnka,
bgr00,
blf00,
blfa1,
blfb1,
blfbk,
blfm1,
blfb5,
blfbw,
blfei,
blfza,
blflr,
blfm2,
bwyt3,
bwyt1,
blfat.
*--- Internal table for spread sheet.
data: t_filedata like alsmex_tabline occurs 0 with header line.
*--- Internal table for Vendor Master Data in Spread Sheet.
data: begin of t_sheet occurs 0,
name1 like lfa1-name1, "vendor name1
name2 like lfa1-name2, "vendor name2
altkn like lfb1-altkn, "previous master record number
bukrs like lfb1-bukrs, "company code
ekorg like lfm1-ekorg, "purchase organization
ktokk like lfa1-ktokk, "account group
stras like lfa1-stras, "street
street4 like lfa1-name4, "street4
pfach like lfa1-pfach, "po box
ort01 like lfa1-ort01, "city
regio like lfa1-regio, "region
pstlz like lfa1-pstlz, "postal code
land1 like lfa1-land1, "country
telf1 like lfa1-telf1, "first telephone number
telfx like lfa1-telfx, "first fax number
stcd1 like lfa1-stcd1, "fed tax ID#
brsch like lfa1-brsch, "commodity code
akont like lfb1-akont, "reconciliation account
mindk like lfb1-mindk, "monitory indicator
zwels like lfb1-zwels, "payment method
reprf like lfb1-reprf, "check double invoice
banka like bnka-banka, "bank name
stret like bnka-stras, "house number and street
city like bnka-ort01, "city
provz like bnka-provz, "bank state
banks like lfbk-banks, "bank country
swift like bnka-swift, "swift code
bankl like lfbk-bankl, "aba#
bankn like lfbk-bankn, "bank account no
zterm like lfb1-zterm, "payment terms
terms like lfm1-zterm, "terms of payment key
end of t_sheet.
*--- Internal table for Vendor Master data in Text File.
data: begin of t_file occurs 0,
s_session type bgr00,
s_header type blf00,
s_blfa1 type blfa1,
s_blfb1 type blfb1,
s_blfbk type blfbk,
s_blfm1 type blfm1,
s_blfbk type blfbk,
s_blfb5 type blfb5,
s_blfza type blfza,
s_blfm1 type blfm1,
s_blfat type blfat,
s_bwyt1 type bwyt1,
s_bwyt3 type bwyt3,
s_blfm2 type blfm2,
s_blfei type blfei1,
s_blfbw type blfbw,
s_blflr type blflr,
end of t_file.
SELECTION SCREEN *****
*---Selection Parameters.
selection-screen begin of block b1 with frame title title1.
parameters: p_xlfile like rlgrap-filename.
parameters: p_txfile type rlgrap-filename.
selection-screen end of block b1.
INITIALIZATION *****
initialization.
*---Initialize text fields for selection-screen.
title1 = 'Selection Parameters'.
AT SELECTION-SCREEN *****
at selection-screen.
at selection-screen on p_xlfile.
perform check_file using p_xlfile.
at selection-screen on value-request for p_xlfile.
perform select_file using p_xlfile.
START-OF-SELECTION *****
start-of-selection.
clear t_sheet.
refresh t_sheet.
*---Upload Spreadsheet.
perform read_file using p_xlfile.
*---Process data into formatted internal table.
perform format_data.
append t_file.
clear t_file.
endloop.
*---Download data to Text file.
perform download_data.
TOP-OF-PAGE *****
top-of-page.
perform top_of_page.
S-U-B-R-O-U-T-I-N-E-S *****
Form TOP_OF_PAGE
Calling the Standard Report Header
form top_of_page.
perform header using 'CREATE FILE FOR'
'VENDOR MASTER UPLOAD'
132.
skip 2.
endform. "TOP_OF_PAGE
Form check_file **
Checking the File entered **
data: p_filename type string.
form check_file using p_filename.
*---The entered File must be Excel spreadsheet.
data: l_length type i,
l_ext(4) type c.
l_length = strlen( p_xlfile ).
subtract 4 from l_length.
l_ext = p_xlfile+l_length(4).
translate l_ext to upper case.
if l_ext <> '.XLS'.
message e009 with 'Only Excel spreadsheets are supported'.
endif.
*---Check if File exits and not empty.
data: l_return(10) type c.
CALL FUNCTION 'WS_QUERY'
EXPORTING
FILENAME = p_filename
QUERY = 'FL'
IMPORTING
RETURN = l_return
EXCEPTIONS
INV_QUERY = 1
NO_BATCH = 2
FRONTEND_ERROR = 3
OTHERS = 4
IF l_return = space or l_return = '0'.
message e530(pj) with p_filename.
ENDIF.
endform. "CHECK_FILE
Form select_file **
form select_file using p_filename like rlgrap-filename.
CALL FUNCTION 'KD_GET_FILENAME_ON_F4'
EXPORTING
PROGRAM_NAME = SYST-REPID
DYNPRO_NUMBER = SYST-DYNNR
FIELD_NAME = ' '
STATIC = 'X'
MASK = ',MS Excel (.xls),.xls.'
CHANGING
FILE_NAME = p_filename
EXCEPTIONS
MASK_TOO_LONG = 1
OTHERS = 2
IF SY-SUBRC <> 0.
MESSAGE e838(29) with p_filename.
ENDIF.
endform. "SELECT_FILE
Form read_file **
form read_file using p_filename like rlgrap-filename.
*---Display status message for User.
CALL FUNCTION 'SAPGUI_PROGRESS_INDICATOR'
EXPORTING
TEXT = 'Uploading Spreadsheet'
*---Upload spreadsheet.
CALL FUNCTION 'ALSM_EXCEL_TO_INTERNAL_TABLE'
EXPORTING
FILENAME = p_filename
I_BEGIN_COL = 1
I_BEGIN_ROW = 1
I_END_COL = 256
I_END_ROW = 65536
TABLES
INTERN = t_filedata
EXCEPTIONS
INCONSISTENT_PARAMETERS = 1
UPLOAD_OLE = 2
OTHERS = 3
IF t_filedata[] is initial.
message i009 with 'NO DATA FOUND IN FILE' p_filename.
stop.
ENDIF.
sort t_filedata by row col.
endform. "READ_FILE
Form format_data **
form format_data.
data: l_index type i.
field-symbols: <fs1>.
*---Display status message for user.
CALL FUNCTION 'SAPGUI_PROGRESS_INDICATOR'
EXPORTING
TEXT = ' Processing Data...'
loop at t_filedata.
l_index = t_filedata-col.
assign component l_index of structure t_sheet to <fs1>.
<fs1> = t_filedata-value.
at end of row.
append t_sheet.
clear t_sheet.
endat.
endloop.
refresh t_filedata.
free t_filedata.
endform. "FORMAT_DATA
Form download_data.
form download_data.
OPEN DATASET p_txfile for OUTPUT.
LOOP at t_file.
TRANSFER t_file to p_txfile.
ENDLOOP.
CLOSE DATASET p_txfile.
IF SY-SUBRC = 0.
WRITE: / 'Excel to Textfile for Vendor Master Upload: ', P_TXFILE.
ENDIF.
endform. "DOWNLOAD_DATA</b>Hi!
You don't need to program the 'translation' from a file into input data for RFBIKR00 yourself. SAP has done this, so that you can do this (nearly) without programming. If you need some special conversion rules, then you can add some coding, but most is possible without.
Have a look at transaction LSMW. It's not so complicated it looks at the first time. Just look at <a href="http://help.sap.com/saphelp_erp2004/helpdata/en/ad/2d54a41d7011d2b42e006094b944c8/frameset.htm">help</a> for the way to use LSMW.
Regards,
Christian
P.S.: sorry for lost your efforts, but you should switch to LSMW -
What is the bdc program for vendor master?
what is the bdc program for vendor master?
Hi,
Find the code here.
And do create your text file data in the order of itab structure.
{report ZBDC_XK01
no standard page heading line-size 255.
data: bdcdata like bdcdata occurs 0 with header line.
data: begin of itab occurs 0,
lifnr like lfa1-lifnr,
bukrs like RF02K-bukrs,
ekorg like RF02K-ekorg,
ktokk like RF02K-ktokk,
anred like lfa1-anred,
name1 like lfa1-name1,
sortl like lfa1-sortl,
land1 like lfa1-land1,
spras like lfa1-spras,
waers like lfm1-waers,
end of itab.
selection-screen begin of block blk1 with frame.
parameters: p_file like rlgrap-filename OBLIGATORY.
selection-screen end of block blk1.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_file.
perform f4_help_p_file.
start-of-selection.
perform get_data.
perform upload.
END-OF-SELECTION.
*& Form f4_help_p_file
text
--> p1 text
<-- p2 text
form f4_help_p_file .
data: v_file like p_file.
CALL FUNCTION 'F4_FILENAME'
IMPORTING
file_name = v_file.
CHECK sy-subrc EQ 0.
p_file = v_file.
endform. " f4_help_p_file
*& Form get_data
text
--> p1 text
<-- p2 text
form get_data .
data: s_file type string.
s_file = p_file.
CALL FUNCTION 'GUI_UPLOAD'
EXPORTING
filename = s_file
FILETYPE = 'ASC'
HAS_FIELD_SEPARATOR = 'X'
HEADER_LENGTH = 0
READ_BY_LINE = 'X'
DAT_MODE = 'D'
CODEPAGE = ' '
IGNORE_CERR = ABAP_TRUE
REPLACEMENT = '#'
CHECK_BOM = ' '
IMPORTING
FILELENGTH =
HEADER =
tables
data_tab = itab
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 <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
stop.
ENDIF.
endform. " get_data
*& Form upload
text
--> p1 text
<-- p2 text
form upload .
loop at itab.
perform bdc_dynpro using 'SAPMF02K' '0100'.
perform bdc_field using 'BDC_CURSOR'
'RF02K-KTOKK'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_field using 'RF02K-LIFNR' itab-lifnr.
perform bdc_field using 'RF02K-BUKRS' '0001'.
perform bdc_field using 'RF02K-EKORG' '1000'.
perform bdc_field using 'RF02K-KTOKK' '0001'.
perform bdc_dynpro using 'SAPMF02K' '0110'.
perform bdc_field using 'BDC_CURSOR'
'LFA1-SPRAS'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_field using 'LFA1-ANRED' itab-anred.
perform bdc_field using 'LFA1-NAME1' itab-name1.
perform bdc_field using 'LFA1-SORTL' itab-sortl.
perform bdc_field using 'LFA1-LAND1' itab-land1.
perform bdc_field using 'LFA1-SPRAS' itab-spras.
perform bdc_dynpro using 'SAPMF02K' '0120'.
perform bdc_field using 'BDC_CURSOR'
'LFA1-KUNNR'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_dynpro using 'SAPMF02K' '0130'.
perform bdc_field using 'BDC_CURSOR'
'LFBK-BANKS(01)'.
perform bdc_field using 'BDC_OKCODE'
'=ENTR'.
perform bdc_dynpro using 'SAPMF02K' '0210'.
perform bdc_field using 'BDC_CURSOR'
'LFB1-AKONT'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_dynpro using 'SAPMF02K' '0215'.
perform bdc_field using 'BDC_CURSOR'
'LFB1-ZTERM'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_dynpro using 'SAPMF02K' '0220'.
perform bdc_field using 'BDC_CURSOR'
'LFB5-MAHNA'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_dynpro using 'SAPMF02K' '0310'.
perform bdc_field using 'BDC_CURSOR'
'LFM1-WAERS'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_field using 'LFM1-WAERS' itab-waers.
perform bdc_dynpro using 'SAPMF02K' '0320'.
perform bdc_field using 'BDC_CURSOR'
'RF02K-LIFNR'.
perform bdc_field using 'BDC_OKCODE'
'=ENTR'.
perform bdc_dynpro using 'SAPLSPO1' '0300'.
perform bdc_field using 'BDC_OKCODE'
'=YES'.
call transaction 'XK01' using bdcdata mode 'A'.
refresh bdcdata.
clear itab.
endloop.
endform. " upload
*& Form bdc_dynpro
text
-->P_0126 text
-->P_0127 text
form bdc_dynpro using program dynpro.
clear bdcdata.
bdcdata-program = program.
bdcdata-dynpro = dynpro.
bdcdata-dynbegin = 'X'.
append bdcdata.
endform. " bdc_dynpro
*& Form bdc_field
text
-->P_0316 text
-->P_0317 text
form bdc_field using fnam fval.
clear bdcdata.
bdcdata-fnam = fnam.
bdcdata-fval = fval.
append bdcdata.
endform. " bdc_field}
Reward points if you find it helpful
Thanks,
Prasanna -
Need standrad program for vendor aging report
Hi
Need standrad program for vendor aging report.
Please reply me only standrad programs.
Point are sure.
Regards,
kumarHi Pankaj
sorry to say that this is not my required program.
I need vendor aging report like s_alr_87012178 tc leads to customer aging report.
Thanks for your effort.
points are awarded.
Regards,
kumar -
IDOC Posting Program for Vendor Master
Hi Guys,
Please give me the Sample Posting Program Vendor master Idoc.
Thanks a lot in advance.
Prabhu.rsearch with BD* in SE93
BD14 - Outbound program for vendor master
BD10 - Outbound Material master
BD12 - Outbound customer master -
Customized LSMW (Batch Input Recording) to upload data for Vendor
Hello Fiends,
can u help me on this object and how to upload in xk01.
Customized LSMW (Batch Input Recording) to upload data for Vendor Master using Transaction code XK01
With best wishes,
Chandu.
Point will be rewarded....Hi,
Go through the following link, you will find your answer
http://www.sapbrain.com
Regards,
Bhaskar -
Need to create a mass upload program for appraisal document creation for multiple employee
Hi Expertise,
I need to create a mass upload program for appraisal document creation for manager and his multiple employee
at a time using tcode appcreate.
Please help me out.
Best regards,
PriyaranjanHi Priyaranjan,
I think you can take the abap'ers help in creating the program. But u need to provide them the exact functionality and the required specifications in creating the appraisal document.
Even tcode also u can get it prepared by Abap'ers.
Thanks and Regards
Balaji -
Hi Expertise,
I need to create a mass upload program for appraisal document creation for manager and his multiple employee
at a time using tcode appcreate.
Please help me out.
Best regards,
PriyaranjanHi,
I have done appraisal document creation for bulk using txt file.
this fm used for single for creation in standard tcode (phap_prepare): 'WZ_HRHAP_0DOC_WZ01_START'.
So create ztcode usinh this fm for single form then record BDC for this tcode and called this tcode in that bdc for bulk creation .
While recording for single I have used manual option instead of automatic . -
I want IDOC for Vendor master updation ( XK01 &XK02 )
Hi
I want to do LSMW in IDOC method for this vendor updation.
So I want IDOC for Vendor master updation ( XK01 & XK02 ).
I want to do both create vendor and change also.
Regards,
Ravi
Edited by: kandukuri ravi on Dec 1, 2008 2:56 PMHi,
For Vendor Master using IDoc's for LSMW,Use Message Type = CREMAS and Basic Type = CREMAS05.
For Basic type 01,02,03...05 are versions which includes more fields in basic type so better use latest version.
Hope it will help you.
Regards,
Sudhakar Reddy.A -
Hi All,
I am trying to use LSMW for Vendor Master upload.
I have gone through all the steps and it is showing correct data in "Display Read Data".
Also the data in "Display Converted Data" is correct.
However when i am running step "Create Batch Input Session" , it is giving following errors:
(1) Transaction XK01 is not supported
(2) editing ws terminated.
Wt could be possible reason for this,I am using standard Batch method for object 0040 and program name RFBIKR00.
("Maintain Object Attributes" details).hello,
in the field mapping step, check whether tcode field has been assigned as XK01 properly.
Reward Points if it is Useful.
Thanks,
Manjunath MS -
Table for field settings for vendor master
Dears,
Can you please let me know which table do i need to refer if I want to know which fields are maintained mandatory, optional, suppres for Vendor master for each account groups.
I have looked into table T077K, but the table values are showing for example ..................................... How to conclude with these values.
Please suggest.
Regards
KameshHi
fiedl selection for vendor Mastr depend upon Vendor account gruop there you can fied out which field is optiona or dispaly like wise
check following link
You maintain the account groups in Customizing for Logistics General under Business Partners - Vendor - Control - Define Account Groups and Field Selection (Vendor).
[http://help.sap.com/saphelp_470/helpdata/en/75/ee0b1c55c811d189900000e8322d00/content.htm]
Regards
Kailas Ugale -
Report for vendor master changes
Good day,
Please can you assist with this issue,
Report S_ALR_87012089,program RFKABL00
Version ECC 6.0
This report does not reflect the old and the new values for changed bank details.
It does not show anything under the old value and shows **deleted** and **created** for new values.
Thanks in advanceYou will have to do configuration in T Codes OBAT and OBAU to achieve what you want in the report.
Check the IMG activity documentation for the following.
SPRO -> IMG -> Financial Accounting -> Accounts Receivable and Accounts Payable -> Vendor Accounts -> Master Records -> Preparations for Changing Vendor Master Records -> Define Field Groups for Vendor Master Records.
SPRO -> IMG -> Financial Accounting -> Accounts Receivable and Accounts Payable -> Vendor Accounts -> Master Records -> Preparations for Changing Vendor Master Records -> Group Fields for Vendor Master Records.
Also read the RFKABL00 program documentation. -
Error in the LSMW for vendor master using standard batch/direct input
I am facing the problem in the LSMW for the Vendor master data. The vendor is initially created for the company code 350 by using LSMW. NOw when I try to uploasd the same vendor using the same LSMW for the company code 450 then I get the error in the Bach input creation as follows:
Batch Input Interface for Vendors
FB012 Session 1 : Special character for 'empty field' is /
FB007 Session 1 session name VNDR_CREATE_ was opened
FB104 Trans. 2 XK01 : Acct already exists; general area not being processed
FB125 ... Data in table BLFA1 cannot be processed
FB016 ... Last header record ...
FB014 ... BLF00-STYPE 1
FB014 ... BLF00-TCODE XK01
FB014 ... BLF00-LIFNR 300951
FB014 ... BLF00-BUKRS 402
FB014 ... BLF00-EKORG /
FB014 ... BLF00-KTOKK VEND
FB017 ... Last data record ...
FB014 ... BLFA1-STYPE 2
FB014 ... BLFA1-TBNAM BLFA1
FB014 ... BLFA1-ANRED /
FB014 ... BLFA1-NAME1 SAVOIE AUTOMATISME DEXIS
This is because when we use XK01 to create the vendor by using thePlease check this answered link:
Re: LSMW for Vendor Master
LSMW Upload vendor master data
Edited by: Afshad Irani on May 5, 2010 12:42 PM -
I am facing problem while working for userexit for vendor master and Editor
Hi,
I am working one userexit for vendor master. My objective is after MK01 transaction, I want to attach MM01 transaction using userexit SAPMF02K on IDES version.
1) Function module is EXIT_SAPMF02K_001 and Include is ZXF05U01.
while duble click on Include is ZXF05U01, I am getting below error.
(Program names ZX...are reserved for includes of exit function groups).
2) Second userexit is Menu exit.
I want to create a sub menu in ABAP Editor under Utilities->Customer Exit.
If double click on Customer exit then MM01 should be called.
So I got one userexit SEU00001 and Function module under that EXIT_SAPLEDITOR_001 and incluse is ZXSEUU21
If I double click on ZXSEUU21 then same error getting displayed
(Program names ZX...are reserved for includes of exit function groups).
Can any one help me to resolve this.
Waiting for quick response.
Best Regards,
BDPHi Bansidhar.,
If you have created the include with same name and implemented youe logic , then it should stop in your include when you have put breakpointin it.
Please try to find the case in which you user exit is called .
It is not necessary that you include will be executed in all cases , please try to use data which is suitable for your case.
Maybe you are looking for
-
OBIEE 10G Embedded Image not displayed on PDF
Hi We have some embedded images (source on network share or on the webserver) on a dashboard. On the screen the images are displayed without problems. But if we want to print the dashboard (f.e. PDF) the images are not printed. In html-view the image
-
I have a problem with the Warp Stabilizer in Adobe Premiere Pro CC on mac
If I want to apply the Verkrümmungsstabilisator on a clip, suddenly only a small neckline of the clip appears in the upper left corner when the effect has finished analyzing. The rest of the clip appears black. Why is that? Is this some wrong setting
-
Please help me tuning this query...
Hi all, Can any body suggest some changes (synthatic) so that it can improve its performance... taking too much time... This is a query used in oracle report... SELECT distinct cc.seg1,cc.seg2,cc.seg3,cc.seg4,cc.seg5,cc.seg6,cc.seg7,cc.seg8,cc.code_
-
How do I send a link to a webpage in Safari when I am using MSN Hotmail? I can't see any way to highlight the link unless I'm sending it through Apple's own email system. Help! iMac Mac OS X (10.4.8) Safari 2.0.4
-
Since I have started trying to upload ~28,000 photos from iPhoto to flickr my iPhoto has been crashing10-15 times per day. 2-3 times/day when I restart iPhoto it has to rebuild/repair my iPhoto database. Now new Events with duplicate photos are sho