Flatfile--XI--SAP PS
Hi everyone,
i have a scenario,where i get a flat file and that need to be loaded to SAP PS.ie Project systems
here,SAP system is ECC.
i get a flat file with details of some project id and the details.....and that need to be sent to approval which is SAP ECC system ...once the approval is done then to SAP PS .ie SAP ECC again....if the appover doesnt approve..then it should go back with some message why that is not being approved....
any idea how to go ahed with this.....
Hi !
BPMs are triggered or started by a receive step that receives the initial message.
Your scenario looks like this (please correct me if I'm wrong):
1) File -> XI -> SAP ECC (for approval)
2) a) SAP ECC -> XI -> SAP PS (if approved)
b) SAP ECC -> XI -> File (?) (if not approved)
Without BPM, there are 2 scenarios, one File->XI->SAP ECC using file/ftp sender adapter and rfc, abap proxy, or IDoc receiver adapter to insert data in SAP ECC.
The other, SAP ECC -> XI -> SAP PS or File, based upon approval, could be done as a single scenario, using XPATH for a content based message routing, to SAP PS if approved or to File if not, based on the content of some fields of the message.
check:
https://www.sdn.sap.com/irj/sdn/wiki?path=/display/xi/enhanced%2breceiver%2bdetermination%2bin%2bsap%2bxi
Using BPM, you could have something like this:
1) receive step (file)
2) send step async to SAP ECC
3) receive step from SAP ECC (use correlation to detect if the incoming message is the same that was sent to SAP ECC). Also use a block with a control step to control the deadline time
4) use a switch step to determine if the message should go to SAP PS receiver or to File receiver.
5) use a send step for each branch of the switch control.
Regards,
Matias
ps: please award points if helpful.
Similar Messages
-
Need help in transferring data from flatfiles to SAP R/3 tables
Hi,
I need to *transfer data in the flatfiles (NON SAP SYSTEM) to SAP R/3 tables*. Can we do it with a help of program ?
Please help me out
Thanks and regards,
Shiva shekar kHi Shiva,
This code will be helpful to you.
*Code used to create BDC
*& Report ZBDC *
*& Example BDC program, which updates net price of item 00010 of a *
*& particular Purchase order(EBELN). *
REPORT ZBDC NO STANDARD PAGE HEADING
LINE-SIZE 132.
Data declaration
TABLES: ekko, ekpo.
TYPES: BEGIN OF t_ekko,
ebeln TYPE ekko-ebeln,
waers TYPE ekko-waers,
netpr TYPE ekpo-netpr,
err_msg(73) TYPE c,
END OF t_ekko.
DATA: it_ekko TYPE STANDARD TABLE OF t_ekko INITIAL SIZE 0,
wa_ekko TYPE t_ekko,
it_error TYPE STANDARD TABLE OF t_ekko INITIAL SIZE 0,
wa_error TYPE t_ekko,
it_success TYPE STANDARD TABLE OF t_ekko INITIAL SIZE 0,
wa_success TYPE t_ekko.
DATA: w_textout LIKE t100-text.
DATA: gd_update TYPE i,
gd_lines TYPE i.
*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.
*Screen declaration
SELECTION-SCREEN BEGIN OF BLOCK block1 WITH FRAME
TITLE text-001. "Purchase order Num
SELECT-OPTIONS: so_ebeln FOR ekko-ebeln OBLIGATORY.
SELECTION-SCREEN END OF BLOCK block1.
SELECTION-SCREEN BEGIN OF BLOCK block2 WITH FRAME
TITLE text-002. "New NETPR value
PARAMETERS: p_newpr(14) TYPE c obligatory. "LIKE ekpo-netpr.
SELECTION-SCREEN END OF BLOCK block2.
*START-OF-SELECTION
START-OF-SELECTION.
Retrieve data from Purchase order table(EKKO)
SELECT ekkoebeln ekkowaers ekpo~netpr
INTO TABLE it_ekko
FROM ekko AS ekko INNER JOIN ekpo AS ekpo
ON ekpoebeln EQ ekkoebeln
WHERE ekko~ebeln IN so_ebeln AND
ekpo~ebelp EQ '10'.
*END-OF-SELECTION
END-OF-SELECTION.
Check data has been retrieved ready for processing
DESCRIBE TABLE it_ekko LINES gd_lines.
IF gd_lines LE 0.
Display message if no data has been retrieved
MESSAGE i003(zp) WITH 'No Records Found'(001).
LEAVE TO SCREEN 0.
ELSE.
Update Customer master data (instalment text)
LOOP AT it_ekko INTO wa_ekko.
PERFORM bdc_update.
ENDLOOP.
Display message confirming number of records updated
IF gd_update GT 1.
MESSAGE i003(zp) WITH gd_update 'Records updated'(002).
ELSE.
MESSAGE i003(zp) WITH gd_update 'Record updated'(003).
ENDIF.
Display Success Report
Check Success table
DESCRIBE TABLE it_success LINES gd_lines.
IF gd_lines GT 0.
Display result report column headings
PERFORM display_column_headings.
Display result report
PERFORM display_report.
ENDIF.
Display Error Report
Check errors table
DESCRIBE TABLE it_error LINES gd_lines.
If errors exist then display errors report
IF gd_lines GT 0.
Display errors report
PERFORM display_error_headings.
PERFORM display_error_report.
ENDIF.
ENDIF.
*& Form DISPLAY_COLUMN_HEADINGS
Display column headings
FORM display_column_headings.
WRITE:2 ' Success Report '(014) COLOR COL_POSITIVE.
SKIP.
WRITE:2 'The following records updated successfully:'(013).
WRITE:/ sy-uline(42).
FORMAT COLOR COL_HEADING.
WRITE:/ sy-vline,
(10) 'Purchase Order'(004), sy-vline,
(11) 'Old Netpr'(005), sy-vline,
(11) 'New Netpr'(006), sy-vline.
WRITE:/ sy-uline(42).
ENDFORM. " DISPLAY_COLUMN_HEADINGS
*& Form BDC_UPDATE
Populate BDC table and call transaction ME22
FORM bdc_update.
PERFORM dynpro USING:
'X' 'SAPMM06E' '0105',
' ' 'BDC_CURSOR' 'RM06E-BSTNR',
' ' 'RM06E-BSTNR' wa_ekko-ebeln,
' ' 'BDC_OKCODE' '/00', "OK code
'X' 'SAPMM06E' '0120',
' ' 'BDC_CURSOR' 'EKPO-NETPR(01)',
' ' 'EKPO-NETPR(01)' p_newpr,
' ' 'BDC_OKCODE' '=BU'. "OK code
Call transaction to update customer instalment text
CALL TRANSACTION 'ME22' USING bdc_tab MODE 'N' UPDATE 'S'
MESSAGES INTO messtab.
Check if update was succesful
IF sy-subrc EQ 0.
ADD 1 TO gd_update.
APPEND wa_ekko TO it_success.
ELSE.
Retrieve error messages displayed during BDC update
LOOP AT messtab WHERE msgtyp = 'E'.
Builds actual message based on info returned from Call transaction
CALL FUNCTION 'MESSAGE_TEXT_BUILD'
EXPORTING
msgid = messtab-msgid
msgnr = messtab-msgnr
msgv1 = messtab-msgv1
msgv2 = messtab-msgv2
msgv3 = messtab-msgv3
msgv4 = messtab-msgv4
IMPORTING
message_text_output = w_textout.
ENDLOOP.
Build error table ready for output
wa_error = wa_ekko.
wa_error-err_msg = w_textout.
APPEND wa_error TO it_error.
CLEAR: wa_error.
ENDIF.
Clear bdc date table
CLEAR: bdc_tab.
REFRESH: bdc_tab.
ENDFORM. " BDC_UPDATE
FORM DYNPRO *
stores values to bdc table *
--> DYNBEGIN *
--> NAME *
--> VALUE *
FORM dynpro USING dynbegin name value.
IF dynbegin = 'X'.
CLEAR bdc_tab.
MOVE: name TO bdc_tab-program,
value TO bdc_tab-dynpro,
'X' TO bdc_tab-dynbegin.
APPEND bdc_tab.
ELSE.
CLEAR bdc_tab.
MOVE: name TO bdc_tab-fnam,
value TO bdc_tab-fval.
APPEND bdc_tab.
ENDIF.
ENDFORM. " DYNPRO
*& Form DISPLAY_REPORT
Display Report
FORM display_report.
FORMAT COLOR COL_NORMAL.
Loop at data table
LOOP AT it_success INTO wa_success.
WRITE:/ sy-vline,
(10) wa_success-ebeln, sy-vline,
(11) wa_success-netpr CURRENCY wa_success-waers, sy-vline,
(11) p_newpr, sy-vline.
CLEAR: wa_success.
ENDLOOP.
WRITE:/ sy-uline(42).
REFRESH: it_success.
FORMAT COLOR COL_BACKGROUND.
ENDFORM. " DISPLAY_REPORT
*& Form DISPLAY_ERROR_REPORT
Display error report data
FORM display_error_report.
LOOP AT it_error INTO wa_error.
WRITE:/ sy-vline,
(10) wa_error-ebeln, sy-vline,
(11) wa_error-netpr CURRENCY wa_error-waers, sy-vline,
(73) wa_error-err_msg, sy-vline.
ENDLOOP.
WRITE:/ sy-uline(104).
REFRESH: it_error.
ENDFORM. " DISPLAY_ERROR_REPORT
*& Form DISPLAY_ERROR_HEADINGS
Display error report headings
FORM display_error_headings.
SKIP.
WRITE:2 ' Error Report '(007) COLOR COL_NEGATIVE.
SKIP.
WRITE:2 'The following records failed during update:'(008).
WRITE:/ sy-uline(104).
FORMAT COLOR COL_HEADING.
WRITE:/ sy-vline,
(10) 'Purchase Order'(009), sy-vline,
(11) 'Netpr'(010), sy-vline,
(73) 'Error Message'(012), sy-vline.
WRITE:/ sy-uline(104).
FORMAT COLOR COL_NORMAL.
ENDFORM. " DISPLAY_ERROR_HEADINGS -
Error messge during data extract from flatfile to sap bw using DataServices
I am extracting data from flat file to SAP BW using Data Services tool. I am able to load all the data from flat file to SAP BW 3.x datasource successfully, but the request in in RED status with error message
Error Encountered at RFC Server Please Check Parameter Setting at BW System.
Can someone please help me how to resolve this issue?I would recommend to post your question here
Data Services and Data Quality
and close the current thread.
Regards,
Stratos -
FIXED LENGTH files supported by SAP
Hi All,
While loading Flatfile in SAP BI system we can specify data file format as either FIXED LENGTH or CSV(in Extraction tab of Datasource).
So my question is which files we can store in a FIXED LENGTH data format.
Thanks,
ShamkantHi,
In Fixed length file we load ASCII file, any file having ( *.TXT or *.DAT ) can be loaded as fixed length.
Thanks
Mayank -
Hi,
I was trying to activate an ODS while loading the data from a FlatFile using SAP BW 7.4.
The Data was loaded completely in correct format in the PSA and also into the New Data and Change log tables in the ODS.
But when trying to activate the ODS, it shows me an error.
The description of the RunTime exception is :
"An exception has occurred which is explained in more detail below. The exception is assigned to class 'CX_PARAMETER_INVALID_RANGE' and was not caught
in procedure "GET_NEXT_PACKAGE" "(METHOD)", nor was it propagated by a RAISING clause. Since the caller of the procedure could not have anticipated this exception, the current program was terminated.
The reason for the exception is: Parameter has invalid value: Parameter IM_TEMPERATURE has invalid value 01011900."
Can you please help me solving this issue?
Thanks,
BhaskarHi Bhaskar,
The message seems to be soft clear, and near of a bad value format, a parameter bad informed.
"Parameter has invalid value: Parameter IM_TEMPERATURE has invalid value01011900" Try to pass a "0" in order to know if this is the parameter or field. And check the Data Type spected.
Regards -
Hi Friends..
Iam using BAPI for to upload data from flatfile to sap instead of BDC.
But after execute this method "BAPI_MATERIAL_SAVEDATA"
Finally no data was updated in master table...
so how can i store the value into base table..
some one told need to give commit statement..
But i dont know where i give the commit statement..
plz reply to me..
Thanks
GowrishankarHi Gowrishankar,
Check the program I have written for MM01 upload using BAPI. Maybe it will be of some help to you.
*& Report ZCN_MM_MATMASTER_BASICVIEW
REPORT zcn_mm_matmaster_basicview MESSAGE-ID zmc_mm_messages.
TABLES: t001l, "Storage Locations
mara, "General Material Data
makt, "Material Descriptions
mbew, "Material Valuation
marc. "Plant Data for Material
DATA: bapi_head LIKE bapimathead,
bapi_makt LIKE bapi_makt, "Material Description
bapi_mara1 LIKE bapi_mara, "Client Data
bapi_marax LIKE bapi_marax,
bapi_marc1 LIKE bapi_marc, "Plant View
bapi_marcx LIKE bapi_marcx,
bapi_mbew1 LIKE bapi_mbew, "Accounting View
bapi_mbewx LIKE bapi_mbewx,
bapi_mard1 LIKE bapi_mard, "Storage View
bapi_mardx LIKE bapi_mardx,
bapi_return LIKE bapiret2.
DATA: BEGIN OF int_makt OCCURS 100.
INCLUDE STRUCTURE bapi_makt.
DATA: END OF int_makt.
DATA: BEGIN OF it_data OCCURS 0,
mat_type(4),
ind_sec(1),
plant(4),
stge_loc(4),
mat_desc(40),
base_uom(3),
old_matno(18),
matl_group(9),
document(22),
po_unit(3),
pur_valkey(4),
mfr_no(10),
manu_mat(40),
vendor_lookup(10),
mrp_type(2),
mrp_ctrler(3),
sm_key(3),
proc_type(1),
sloc_exprc(4),
stge_bin(10),
issue_unit(3),
cc_ph_inv(1),
price_ctrl(1),
val_class(4),
moving_pr(11),
price_unit(5),
profit_ctr(10),
matnr(18),
END OF it_data,
is_data LIKE it_data.
DATA: BEGIN OF it_error OCCURS 0,
mat_type(4),
ind_sec(1),
plant(4),
stge_loc(4),
mat_desc(40),
base_uom(3),
old_matno(18),
matl_group(9),
document(22),
po_unit(3),
pur_valkey(4),
mfr_no(10),
manu_mat(40),
vendor_lookup(10),
mrp_type(2),
mrp_ctrler(3),
sm_key(3),
proc_type(1),
sloc_exprc(4),
stge_bin(10),
issue_unit(3),
cc_ph_inv(1),
price_ctrl(1),
val_class(4),
moving_pr(11),
price_unit(5),
profit_ctr(10),
matnr(18),
END OF it_error,
is_error LIKE it_error.
DATA: bdc_tab LIKE bdcdata OCCURS 0 WITH HEADER LINE.
DATA : g_file TYPE string.
DATA : BEGIN OF data_mat OCCURS 0,
datastring TYPE string,
END OF data_mat.
DATA: record(500).
DATA: gv_count TYPE i VALUE 0.
DATA lv_string TYPE string.
TYPES: BEGIN OF ty_string_tab,
line(255),
END OF ty_string_tab.
DATA i_string_tab TYPE STANDARD TABLE OF ty_string_tab.
********************------SELECTION SCREEN----**************************
SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.
PARAMETERS: p_file TYPE ibipparms-path.
PARAMETERS: r_local RADIOBUTTON GROUP radi,
r_apps RADIOBUTTON GROUP radi.
SELECTION-SCREEN END OF BLOCK b1.
SELECTION-SCREEN BEGIN OF BLOCK b2 WITH FRAME TITLE text-003.
PARAMETERS : p_downld LIKE rlgrap-filename OBLIGATORY.
SELECTION-SCREEN END OF BLOCK b2.
*******************AT SELECTION SCREEN *********************
AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_file.
CALL FUNCTION 'F4_FILENAME'
EXPORTING
program_name = syst-cprog
dynpro_number = syst-dynnr
IMPORTING
file_name = p_file.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_downld.
PERFORM get_local_file USING p_downld.
* S T A R T O F S E L E C T I O N
START-OF-SELECTION.
g_file = p_file.
PERFORM upload USING g_file. "Upload takes the file from the presentation
PERFORM conversion_extendedview.
PERFORM download_errors.
*& Form upload
* text
* --> p1 text
* <-- p2 text
FORM upload USING lv_file .
IF r_apps = 'X'.
OPEN DATASET lv_file
FOR INPUT IN TEXT MODE
ENCODING DEFAULT.
IF sy-subrc <> 0.
WRITE: / text-002, sy-subrc.
STOP.
ELSE.
DO.
READ DATASET lv_file INTO record.
SPLIT record AT '~' INTO
it_data-mat_type
it_data-ind_sec
it_data-plant
it_data-stge_loc
it_data-mat_desc
it_data-base_uom
it_data-old_matno
it_data-matl_group
it_data-document
it_data-po_unit
it_data-pur_valkey
it_data-mfr_no
it_data-manu_mat
it_data-vendor_lookup
it_data-mrp_type
it_data-mrp_ctrler
it_data-sm_key
it_data-proc_type
it_data-sloc_exprc
it_data-stge_bin
it_data-issue_unit
it_data-cc_ph_inv
it_data-price_ctrl
it_data-val_class
it_data-moving_pr
it_data-price_unit
it_data-profit_ctr
it_data-matnr.
APPEND it_data.
CLEAR it_data.
ENDDO.
CLOSE DATASET lv_file.
ENDIF.
ELSEIF r_local = 'X'.
CALL FUNCTION 'GUI_UPLOAD'
EXPORTING
filename = lv_file
filetype = 'ASC'
has_field_separator = '~'
header_length = 0
read_by_line = 'X'
* DAT_MODE = ' '
* CODEPAGE = ' '
ignore_cerr = 'X'
replacement = '#'
* CHECK_BOM = ' '
* VIRUS_SCAN_PROFILE =
* NO_AUTH_CHECK = ' '
* IMPORTING
* FILELENGTH =
* HEADER =
TABLES
data_tab = data_mat
* 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.
ELSE.
LOOP AT data_mat.
SPLIT data_mat-datastring AT '~' INTO
it_data-mat_type
it_data-ind_sec
it_data-plant
it_data-stge_loc
it_data-mat_desc
it_data-base_uom
it_data-old_matno
it_data-matl_group
it_data-document
it_data-po_unit
it_data-pur_valkey
it_data-mfr_no
it_data-manu_mat
it_data-vendor_lookup
it_data-mrp_type
it_data-mrp_ctrler
it_data-sm_key
it_data-proc_type
it_data-sloc_exprc
it_data-stge_bin
it_data-issue_unit
it_data-cc_ph_inv
it_data-price_ctrl
it_data-val_class
it_data-moving_pr
it_data-price_unit
it_data-profit_ctr
it_data-matnr.
APPEND it_data.
CLEAR it_data.
ENDLOOP.
ENDIF.
ENDIF.
ENDFORM. " upload
*& Form conversion_extendedview
* text
* --> p1 text
* <-- p2 text
FORM conversion_extendedview .
DATA: lv_matnr LIKE mara-matnr,
lv_lifnr LIKE lfb1-lifnr.
LOOP AT it_data INTO is_data.
CLEAR: lv_matnr,
lv_lifnr.
SELECT SINGLE matnr FROM mara INTO lv_matnr
WHERE bismt = is_data-old_matno AND
meins = is_data-base_uom.
IF sy-subrc NE 0.
MOVE is_data TO is_error.
APPEND is_error TO it_error.
CLEAR is_error.
CONTINUE.
ENDIF.
SELECT SINGLE lifnr INTO lv_lifnr FROM lfb1
WHERE altkn = is_data-vendor_lookup.
IF sy-subrc EQ 0.
SELECT SINGLE lifnr INTO lv_lifnr FROM lfa1
WHERE lifnr = lv_lifnr AND
ktokk = 'ZMNF'.
IF sy-subrc NE 0.
lv_lifnr = ' '.
ENDIF.
ELSE.
lv_lifnr = ' '.
ENDIF.
* Header
bapi_head-material = lv_matnr.
bapi_head-ind_sector = 'C'.
bapi_head-matl_type = is_data-mat_type.
bapi_head-basic_view = 'X'.
bapi_head-purchase_view = 'X'.
bapi_head-account_view = 'X'.
bapi_head-storage_view = 'X'.
IF is_data-mat_type = 'ROH'.
bapi_head-mrp_view = 'X'.
bapi_head-cost_view = 'X'.
ENDIF.
* Material Description
REFRESH int_makt.
int_makt-langu = 'EN'.
int_makt-matl_desc = is_data-mat_desc.
APPEND int_makt.
* Client Data - Basic
bapi_mara1-matl_group = is_data-matl_group.
bapi_mara1-base_uom = is_data-base_uom.
bapi_mara1-old_mat_no = is_data-old_matno.
bapi_mara1-document = is_data-document.
bapi_mara1-po_unit = is_data-po_unit.
bapi_mara1-pur_valkey = is_data-pur_valkey.
bapi_mara1-mfr_no = lv_lifnr.
bapi_mara1-manu_mat = is_data-manu_mat.
bapi_marax-old_mat_no = 'X'.
bapi_marax-document = 'X'.
bapi_marax-po_unit = 'X'.
bapi_marax-pur_valkey = 'X'.
bapi_marax-mfr_no = 'X'.
bapi_marax-manu_mat = 'X'.
bapi_marax-matl_group = 'X'.
bapi_marax-base_uom = 'X'.
* Plant - Purchasing
bapi_marc1-plant = is_data-plant.
bapi_marc1-mrp_type = 'ND'.
bapi_marc1-mrp_ctrler = is_data-plant.
bapi_marc1-sm_key = '000'.
bapi_marc1-proc_type = 'F'.
bapi_marc1-issue_unit = is_data-issue_unit.
bapi_marc1-cc_ph_inv = is_data-cc_ph_inv.
bapi_marc1-profit_ctr = is_data-profit_ctr.
IF is_data-mat_type = 'ROH'.
bapi_marc1-availcheck = 'KP'.
bapi_marcx-availcheck = 'X'.
ENDIF.
bapi_marcx-plant = is_data-plant.
bapi_marcx-mrp_type = 'X'.
bapi_marcx-mrp_ctrler = 'X'.
bapi_marcx-sm_key = 'X'.
bapi_marcx-proc_type = 'X'.
bapi_marcx-issue_unit = 'X'.
bapi_marcx-cc_ph_inv = 'X'.
bapi_marcx-profit_ctr = 'X'.
* Storage View
bapi_mard1-plant = is_data-plant.
bapi_mard1-stge_loc = is_data-stge_loc.
bapi_mard1-stge_bin = is_data-stge_bin.
bapi_mardx-plant = is_data-plant.
bapi_mardx-stge_loc = is_data-stge_loc.
bapi_mardx-stge_bin = 'X'.
* Accounting
bapi_mbew1-val_area = is_data-plant.
IF is_data-mat_type = 'ROH'.
bapi_mbew1-val_class = '1000'.
ELSEIF is_data-mat_type = 'ERSA'.
bapi_mbew1-val_class = '1001'.
ENDIF.
bapi_mbew1-price_ctrl = 'V'.
bapi_mbew1-moving_pr = is_data-moving_pr.
bapi_mbew1-price_unit = '1'.
bapi_mbewx-val_area = is_data-plant.
bapi_mbewx-val_class = 'X'.
bapi_mbewx-moving_pr = 'X'.
bapi_mbewx-price_ctrl = 'X'.
bapi_mbewx-price_unit = 'X'.
* WRITE:/ bapi_head, bapi_marc1.
CALL FUNCTION 'BAPI_MATERIAL_SAVEDATA'
EXPORTING
headdata = bapi_head
clientdata = bapi_mara1
clientdatax = bapi_marax
plantdata = bapi_marc1
plantdatax = bapi_marcx
* FORECASTPARAMETERS =
* FORECASTPARAMETERSX =
* PLANNINGDATA =
* PLANNINGDATAX =
storagelocationdata = bapi_mard1
storagelocationdatax = bapi_mardx
valuationdata = bapi_mbew1
valuationdatax = bapi_mbewx
* WAREHOUSENUMBERDATA =
* WAREHOUSENUMBERDATAX =
* SALESDATA = BAPI_MVKE1
* SALESDATAX = BAPI_MVKEX
* STORAGETYPEDATA =
* STORAGETYPEDATAX =
IMPORTING
return = bapi_return
TABLES
materialdescription = int_makt
* UNITSOFMEASURE =
* UNITSOFMEASUREX =
* INTERNATIONALARTNOS =
* MATERIALLONGTEXT =
* TAXCLASSIFICATIONS =
* RETURNMESSAGES =
* PRTDATA =
* PRTDATAX =
* EXTENSIONIN =
* EXTENSIONINX =
* IF sy-subrc EQ 0.
CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'.
* ENDIF.
* IF bapi_return-type = 'E'.
* gv_count = gv_count + 1.
* is_error-old_matno = is_data-old_matno.
* is_error-plant = is_data-plant.
* is_error-stge_loc = is_data-stge_loc.
* APPEND is_error TO it_error.
* CLEAR is_error.
* WRITE:/'For Old Material Number',is_data-old_matno,bapi_return-message.
* ENDIF.
ENDLOOP.
* WRITE: 'Total Records in Error', gv_count.
PERFORM concatenate_into_string.
PERFORM download_data.
ENDFORM. "conversion_extendedview
*& Form get_local_file
* text
* -->P_P_DOWNLOAD text
FORM get_local_file USING p_p_download.
CALL FUNCTION 'WS_FILENAME_GET'
EXPORTING
mask = ',*.*,*.*.'
mode = 'S'
title = 'Lookup for Upload file'(013)
IMPORTING
filename = p_p_download
EXCEPTIONS
inv_winsys = 1
no_batch = 2
selection_cancel = 3
selection_error = 4
OTHERS = 5.
IF sy-subrc <> 0.
ENDIF.
ENDFORM. " get_local_file
*& Form concatenate_into_string
* text
* --> p1 text
* <-- p2 text
FORM concatenate_into_string .
DATA: lw_error LIKE LINE OF it_error.
DATA: lw_tab_string LIKE LINE OF i_string_tab,
lw_matnr(10),
lw_plant(3),
lw_stloc(4).
LOOP AT it_error INTO is_error.
MOVE is_error-old_matno TO lw_matnr.
MOVE is_error-plant TO lw_plant.
MOVE is_error-stge_loc TO lw_stloc.
CONCATENATE lw_matnr lw_plant lw_stloc INTO lv_string SEPARATED BY '~'.
MOVE lv_string TO lw_tab_string.
APPEND lw_tab_string TO i_string_tab.
CLEAR: lv_string, lw_tab_string.
ENDLOOP.
ENDFORM. " concatenate_into_string
*& Form download_data
* text
* --> p1 text
* <-- p2 text
FORM download_data .
DATA: lv_file TYPE string.
* Move file name to filename of type string acceptable by GUI_DOWNLOAD
lv_file = p_downld.
CALL FUNCTION 'GUI_DOWNLOAD'
EXPORTING
* BIN_FILESIZE =
filename = lv_file
filetype = 'ASC'
* APPEND = ' '
* WRITE_FIELD_SEPARATOR = ' '
* HEADER = '00'
* TRUNC_TRAILING_BLANKS = ' '
* WRITE_LF = 'X'
* COL_SELECT = ' '
* COL_SELECT_MASK = ' '
* DAT_MODE = ' '
* IMPORTING
* FILELENGTH =
TABLES
* data_tab = i_empdata
data_tab = i_string_tab
EXCEPTIONS
file_write_error = 1
no_batch = 2
gui_refuse_filetransfer = 3
invalid_type = 4
no_authority = 5
unknown_error = 6
header_not_allowed = 7
separator_not_allowed = 8
filesize_not_allowed = 9
header_too_long = 10
dp_error_create = 11
dp_error_send = 12
dp_error_write = 13
unknown_dp_error = 14
access_denied = 15
dp_out_of_memory = 16
disk_full = 17
dp_timeout = 18
file_not_found = 19
dataprovider_exception = 20
control_flush_error = 21
OTHERS = 22.
IF sy-subrc EQ 0.
MESSAGE s999 WITH 'File saved successfully'(001) 'to' p_file.
ELSE.
MESSAGE s999 WITH 'Error in creating File'(002).
ENDIF.
ENDFORM. " download_data
*& Form download_errors
* text
* --> p1 text
* <-- p2 text
FORM download_errors .
DATA: gv_file TYPE string.
gv_file = p_downld.
CALL FUNCTION 'GUI_DOWNLOAD'
EXPORTING
* BIN_FILESIZE =
filename = gv_file
filetype = 'ASC'
* APPEND = ' '
write_field_separator = '~'
* HEADER = '00'
* TRUNC_TRAILING_BLANKS = ' '
* WRITE_LF = 'X'
* COL_SELECT = ' '
* COL_SELECT_MASK = ' '
* DAT_MODE = ' '
* CONFIRM_OVERWRITE = ' '
* NO_AUTH_CHECK = ' '
* CODEPAGE = ' '
* IGNORE_CERR = ABAP_TRUE
* REPLACEMENT = '#'
* WRITE_BOM = ' '
* TRUNC_TRAILING_BLANKS_EOL = 'X'
* WK1_N_FORMAT = ' '
* WK1_N_SIZE = ' '
* WK1_T_FORMAT = ' '
* WK1_T_SIZE = ' '
* WRITE_EOL = ABAP_TRUE
* IMPORTING
* FILELENGTH =
TABLES
data_tab = it_error
* FIELDNAMES =
* EXCEPTIONS
* FILE_WRITE_ERROR = 1
* NO_BATCH = 2
* GUI_REFUSE_FILETRANSFER = 3
* INVALID_TYPE = 4
* NO_AUTHORITY = 5
* UNKNOWN_ERROR = 6
* HEADER_NOT_ALLOWED = 7
* SEPARATOR_NOT_ALLOWED = 8
* FILESIZE_NOT_ALLOWED = 9
* HEADER_TOO_LONG = 10
* DP_ERROR_CREATE = 11
* DP_ERROR_SEND = 12
* DP_ERROR_WRITE = 13
* UNKNOWN_DP_ERROR = 14
* ACCESS_DENIED = 15
* DP_OUT_OF_MEMORY = 16
* DISK_FULL = 17
* DP_TIMEOUT = 18
* FILE_NOT_FOUND = 19
* DATAPROVIDER_EXCEPTION = 20
* CONTROL_FLUSH_ERROR = 21
* OTHERS = 22
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ENDFORM. " download_errors
Regards
Aneesh. -
hi gurus.
i have to bring the datas from a flatfile to SAP. i have written a code but am getting an error in phone in split statement. There are many phone number in the flatfile in unformatted form. some as mobile no,landline no, some with off: no and res: no how to split all the words and only the phone no i want. This is the sample data
07453/234802,231843,232277
08377/264265,R.254276
2417121/2417151/2417191
08377/551265,R.554276
Off:71 Resi:107
02465/22263,22210,Nanded
Off:20 Resi:38 & 267
(220)-6785,7321,7325,R:1707
244080, R.244172
445019
help me in sloving the problem
REPORT ZVKFO .
DATA : DSN(50) TYPE C VALUE '/sapmnt/bdc/fone.txt',
ROW(30) TYPE C,
DEL TYPE C VALUE '/',
DEL1 TYPE C VALUE '-',
DEL2 TYPE C VALUE ','.
DATA : BEGIN OF ITAB OCCURS 0,
PHONE(10) TYPE C,
END OF ITAB.
OPEN DATASET DSN FOR INPUT IN TEXT MODE ENCODING DEFAULT .
READ DATASET DSN INTO ITAB.
DO 100 TIMES.
SPLIT ITAB AT DEL INTO PHONE.
*split itab at del1 into phone.
*split itab at del2 into phone.
ITAB-PHONE = ROW.
ENDDO.
WRITE : ITAB-PHONE.Hi,
the statement u r using is wrong. It should be
DATA: VALUE TYPE STRING.
SPLIT ITAB-PHONE AT DEL INTO ITAB-PHONE VALUE.
Always when u split the itab-phone the string will be split into two. so u need to give two variables after the into statement so the one will have first half of the string and the other will have the second half.
also i didnt get ur point u r splitting ur record to PHONE and assigning ROW to it. Also there is no append statement for the table.
thanks,
Srinath. -
when the idoc is in ascii or edifact format , we will use third party tools for mapping or how to approach this kind of situation
Hi Jackson,
thank you for your suggestion!
Just now, I called the customer. They used seeburger adapter before. Now they can use Seeburger Adapter to read IDoc ASCII Format.
But they want to discard seeburger in the future. Therefore it is not neccessary to integrate Seeburg adapter into XI.
Have you heard anything about fileport in SAP?
Can I just transfer flatfile to SAP internal folder and SAP picks files and convert them into IDoc-Schema automatically?
Regards
Rene -
Can PI handle IDocs in ASCII Format directly, without ContentConversion?
Hi,
I got IDocs from vendor in ASCII Format, like that:
EDI_DC 700 64 2SAPPRO LSSAPROM100...
E1EDK01 000001 DOL
E1EDKA1 000002 LF 001012323443 Fashy Co., LTD....
E1EDKA1 000003 RE YXZ Co., LTD....
E1EDK02 000008 009234255234....
E1EDK02 000009 123432432534....
E1EDK03....
E1EDK05...
E1EDK05...
My Question: whehter there is an adpater or a function in XI7.0 that can input such IDoc in ASCII Format without ContentConversion?
Otherwise, I must ask vendor to provide me IDoc in XML Format.
Any hints would be appreciated!
Regards
ReneHi Jackson,
thank you for your suggestion!
Just now, I called the customer. They used seeburger adapter before. Now they can use Seeburger Adapter to read IDoc ASCII Format.
But they want to discard seeburger in the future. Therefore it is not neccessary to integrate Seeburg adapter into XI.
Have you heard anything about fileport in SAP?
Can I just transfer flatfile to SAP internal folder and SAP picks files and convert them into IDoc-Schema automatically?
Regards
Rene -
how i can upload table formated data from flatfile to SAP
data in flat file
EX: XK01- bank details of vendor
country bank code account no
DE,IN 120210,125635 568956,9875652
DE 25689 56986Hi,
Using LSMW, data can be uploaded to the desired SAP table.
There are certain steps to be executed to do so. In this , I am telling you to do the uploading using LSMW and Batch Input Session .
Steps :
1.T-code for this is LSMW .
2.Create Project and subproject.
3.Maintain Object Attributes.
4.Maintain Source Structures
5.Maintain Source Fields
6.Maintain Structure Relations
7.Maintain Field Mapping and Conversion Rules
8.Maintain Fixed Values, Translations, User-Defined Routines
9.Specify Files ( Flat Files )
10.Assign Files ( to check for the correct assignment of files to the source structure you created in step 4 )
11. Read Data
12. Display Read Data ( optional)
13. Convert Data
14. Display Convert data(optional)
15. Create Batch Input Session
16.Run Batch Input Session
once you execute these steps, you should check the SAP Table for the data. This is to verify that the data has been correctly loaded to the table . The step is called Reconcillation.
Regards,
Kunal.
Note : do let me know if you want explanation of any of the steps in details. -
Hi all!
In Support Project we track issues related to data loading. Also said data loading process carried out through Process Chains & Infopackage groups
So, Can u pls explain what is
Data Loading
Process Chains
Onfo Package Groups.
<b><b>
Please reply guys</b></b>
Thanks in advance.Hi Rahul,
The terms which u are used...comes in BIW....
Dataloading is nothin but loadin the data from R/3 to sap or flatfile to sap ..etc..
there are several stages comes in picture for dataloading....finally data will b loaded to INFOCUBE or ODS(in BIW)...from infocube we can generate reports..
Process chains : ther area several stages for dataloading....data is moved from one to another....instead of doing it manually ..if u wanna make automated..we wil go for process chains.....
Infopackage : this is used to schedule the data ...
to know more about it.....post this question in BIW forum.....
Regards,..
Balaji ( Assign points if this is useful....) -
Shedule line data upload program
Hi experts
I have created this program to upload data from flatfile to SAP.My this program is not uploading any record from my flat file...I debugg the program but its showing data in internal table...after executing this report its not showing the success uploaded message...it shows no data uploaded in system..I cant understand why its not uploading any record in database.
my flat file structure is like this :
K156 31-AUG-2007 80000M797A0-C67 24 A1-3 NAGARE COMP 1-1 100
K156 31-AUG-2007 80000M798A0-C67 120 A1-3 NAGARE COMP 1-1 100
K156 31-AUG-2007 80000M799A0-C67 120 A1-3 NAGARE COMP 1-1 100
K156 31-AUG-2007 85051M63BB3-BCR 54 A1-6 NAGARE COMP 1-1 100
K156 31-AUG-2007 85051M67K00-EDU 28 A3-4 NAGARE COMP 1-1 100
Thanks in advanceHi experts
I have created this program to upload data from flatfile to SAP.My this program is not uploading any record from my flat file...I debugg the program but its showing data in internal table...after executing this report its not showing the success uploaded message...it shows no data uploaded in system..I cant understand why its not uploading any record in database.
my flat file structure is like this :
K156 31-AUG-2007 80000M797A0-C67 24 A1-3 NAGARE COMP 1-1 100
K156 31-AUG-2007 80000M798A0-C67 120 A1-3 NAGARE COMP 1-1 100
K156 31-AUG-2007 80000M799A0-C67 120 A1-3 NAGARE COMP 1-1 100
K156 31-AUG-2007 85051M63BB3-BCR 54 A1-6 NAGARE COMP 1-1 100
K156 31-AUG-2007 85051M67K00-EDU 28 A3-4 NAGARE COMP 1-1 100
Thanks in advance -
Extraction from sap r/3 tables to flatfile
hello Guru's
i am new to this feild. we have a requirement that we need to extract data from hr feilds of different hr tables in sap to flat file. we have a flatfile structure. we don't have some of feilds in sap R/3 compared to flatfile. we need to fill those feilds also with logic.
plz show me rigth direction with example code so that i can slove the problem.
thanks
radHi,
Check this sample program.
REPORT zdownempdata .
INFOTYPES: 0000, 0001, 0007, 0008, 0121, 0615.
NODES: pernr.
TABLES: t001p.
TYPES: BEGIN OF t_employee,
INCLUDE STRUCTURE hrms_biw_io_occupancy.
begda TYPE begda,
endda TYPE endda,
pernr TYPE pernr_d,
rfpnr TYPE rfpnr,
bukrs TYPE bukrs,
werks TYPE persa,
btrtl TYPE btrtl,
persg TYPE persg,
persk TYPE persk,
orgeh TYPE orgeh,
stell TYPE stell,
plans TYPE plans,
kokrs TYPE mast_coar,
kostl TYPE mast_cctr,
abkrs TYPE abkrs,
molga TYPE molga,
trfar TYPE trfar,
trfgb TYPE trfgb,
trfkz TYPE trfkz,
trfgr TYPE trfgr,
trfst TYPE trfst,
bsgrd TYPE bsgrd,
ansal TYPE ansal_15,
ancur TYPE ancur,
empct TYPE empct,
stat2 TYPE stat2,
ncsdate TYPE hiredate,
sltyp TYPE p_sltyp,
slreg TYPE p_slreg,
slgrp TYPE p_slgrp,
sllev TYPE p_sllvl,
ansvh TYPE ansvh,
vdsk1 TYPE vdsk1,
sname TYPE smnam,
END OF t_employee.
DATA: it_employee TYPE STANDARD TABLE OF t_employee INITIAL SIZE 0,
wa_employee TYPE t_employee.
TYPES: BEGIN OF t_emptexts,
INCLUDE STRUCTURE hrms_bw_txt_employee.
DATEFROM TYPE RSDATEFROM,
DATETO TYPE RSDATETO,
PERNR TYPE PERSNO,
TXTMD TYPE EMNAM,
END OF t_emptexts.
DATA: it_emptexts TYPE STANDARD TABLE OF t_emptexts INITIAL SIZE 0,
wa_emptexts TYPE t_emptexts.
TYPES: BEGIN OF t_contract,
INCLUDE STRUCTURE pa0615.
pernr TYPE p0615-pernr,
begda TYPE p0615-begda,
endda TYPE p0615-endda,
aedtm TYPE p0615-aedtm,
ctype TYPE p0615-ctype,
cbeg TYPE p0615-cbeg,
cend TYPE p0615-cend,
END OF t_contract.
DATA: it_contract TYPE STANDARD TABLE OF t_contract INITIAL SIZE 0,
wa_contract TYPE t_contract.
DATA: it_tabemp TYPE filetable,
gd_subrcemp TYPE i,
it_tabempt TYPE filetable,
gd_subrcempt TYPE i,
it_tabcont TYPE filetable,
gd_subrccont TYPE i.
DATA: gd_downfile TYPE string.
SELECTION-SCREEN BEGIN OF BLOCK block1 WITH FRAME TITLE text-001.
PARAMETERS: p_emp LIKE rlgrap-filename,
p_empt LIKE rlgrap-filename,
p_cont LIKE rlgrap-filename.
SELECTION-SCREEN END OF BLOCK block1.
*at selection-screen
AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_emp.
REFRESH: it_tabemp.
CALL METHOD cl_gui_frontend_services=>file_open_dialog
EXPORTING
window_title = 'Select File'
default_filename = '*.xls'
initial_directory = 'C:\'
multiselection = ' ' "No multiple selection
CHANGING
file_table = it_tabemp
rc = gd_subrcemp.
LOOP AT it_tabemp INTO p_emp.
ENDLOOP.
*at selection-screen
AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_empt.
REFRESH: it_tabemp.
CALL METHOD cl_gui_frontend_services=>file_open_dialog
EXPORTING
window_title = 'Select File'
default_filename = '*.xls'
initial_directory = 'C:\'
multiselection = ' ' "No multiple selection
CHANGING
file_table = it_tabempt
rc = gd_subrcempt.
LOOP AT it_tabempt INTO p_empt.
ENDLOOP.
*at selection-screen
AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_cont.
REFRESH: it_tabcont.
CALL METHOD cl_gui_frontend_services=>file_open_dialog
EXPORTING
window_title = 'Select File'
default_filename = '*.xls'
initial_directory = 'C:\'
multiselection = ' ' "No multiple selection
CHANGING
file_table = it_tabcont
rc = gd_subrccont.
LOOP AT it_tabcont INTO p_cont.
ENDLOOP.
*START-OF-SELECTION.
START-OF-SELECTION.
GET pernr.
Selecting the latest infotype record
rp_provide_from_last p0000 space pn-begda pn-endda.
rp_provide_from_last p0001 space pn-begda pn-endda.
rp_provide_from_last p0007 space pn-begda pn-endda.
rp_provide_from_last p0008 space pn-begda pn-endda.
rp_provide_from_last p0121 space pn-begda pn-endda.
rp_provide_from_last p0615 space pn-begda pn-endda.
MOVE-CORRESPONDING p0001 TO wa_employee.
wa_employee-rfpnr = p0121-rfp01. "?????
MOVE-CORRESPONDING p0007 TO wa_employee.
MOVE-CORRESPONDING p0008 TO wa_employee.
MOVE-CORRESPONDING p0000 TO wa_employee.
SELECT SINGLE molga
FROM t001p
INTO wa_employee-molga
WHERE werks EQ p0001-werks AND
btrtl EQ p0001-btrtl.
SELECT SINGLE trfkz
FROM t503
INTO wa_employee-trfkz
WHERE persg EQ p0001-persg AND
persk EQ p0001-persk.
CALL FUNCTION 'HR_ENTRY_DATE'
EXPORTING
persnr = pernr-pernr
RCLAS =
BEGDA = '18000101'
ENDDA = '99991231'
VARKY =
IMPORTING
entrydate = wa_employee-ncsdate
TABLES
ENTRY_DATES =
EXCEPTIONS
ENTRY_DATE_NOT_FOUND = 1
PERNR_NOT_ASSIGNED = 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.
append employee data
APPEND wa_employee TO it_employee.
CLEAR: wa_employee.
wa_emptexts-datefrom = p0001-begda.
wa_emptexts-dateto = p0001-endda.
wa_emptexts-pernr = p0001-pernr.
wa_emptexts-txtmd = p0001-ename.
append employee texts data
APPEND wa_emptexts TO it_emptexts.
CLEAR: wa_emptexts.
MOVE-CORRESPONDING p0615 TO wa_contract.
append employee contract data
APPEND wa_contract TO it_contract.
CLEAR: wa_contract.
*END-OF-SELECTION.
END-OF-SELECTION.
download employee data
IF NOT p_emp IS INITIAL.
gd_downfile = p_emp.
CALL FUNCTION 'GUI_DOWNLOAD'
EXPORTING
filename = gd_downfile
filetype = 'ASC'
write_field_separator = 'X'
TABLES
data_tab = it_employee.
IF sy-subrc EQ 0.
WRITE:/ 'Employee file downloaded to',
gd_downfile.
ELSE.
WRITE:/ 'There was an error downloading Employee file to',
gd_downfile.
ENDIF.
ENDIF.
download employee texts data
IF NOT p_empt IS INITIAL.
gd_downfile = p_empt.
CALL FUNCTION 'GUI_DOWNLOAD'
EXPORTING
filename = gd_downfile
filetype = 'ASC'
write_field_separator = 'X'
TABLES
data_tab = it_emptexts.
IF sy-subrc EQ 0.
WRITE:/ 'Employee text file downloaded to',
gd_downfile.
ELSE.
WRITE:/ 'There was an error downloading Employee text file to',
gd_downfile.
ENDIF.
ENDIF.
download contract data
IF NOT p_cont IS INITIAL.
gd_downfile = p_cont.
CALL FUNCTION 'GUI_DOWNLOAD'
EXPORTING
filename = gd_downfile
filetype = 'ASC'
write_field_separator = 'X'
TABLES
data_tab = it_contract.
IF sy-subrc EQ 0.
WRITE:/ 'Employee contract file downloaded to',
gd_downfile.
ELSE.
WRITE:/ 'There was an error downloading Employee contract file to',
gd_downfile.
ENDIF.
ENDIF.
- Selvapandian Arunachalam -
Data extraction from sap r/3 to flatfile
hello Guru's
i am new to this feild. i got a requirement in such a way i have to extract data from feilds of different tables to flatfile.
( actual Scenario is we want to send data to sybase server through flatfile)
plz send me some documents how to proceed with the specification
usefull code in this regard is lot helpfull.
thanks and regards
ajHello Raja,
Here are some simple steps ...
When you want to load data from a flat file, there is no process of datasource replication. The datasource has to be created manually on the BW system itself. When creating this datasource you start from the InfoSource and assign the source system for flat file load. This is usually something like PC_FILE or FLATFILE.
Then you can start creating the datasource. You need to mention the field names in this datasource. Note that in your flat file, the sequence of fields must exactly match the sequence of fields in the datasource, else the data will be wrongly mapped.
On the same screen and tab you can also do a preview of the data that will be loaded. Click the preview button and put in the path of the file. Mention other details like header row, and number of rows to be displayed and then you will be able to judge if the data is being loaded correctly or not.
When loading the data, then file cannot be open else you will get an error message. Also to be able to schedule the flat file loads in process chains, the file cannot be on your PC. It has to be on the application server.
This is some basic info. Please post back if you need details on any aspect.
Hope this helps...
Assigning points is the way to thanks in sdn. -
Load a flat file into BW-BPS using SAP GUI
Hi,
We are using BW BPS 3.5 version, i implemented how to guide " How to load a flat file into BW-BPS using SAP GUI" successfully without any errors.
I inlcuded three infoobjects in the text file costelemt, Posting period and amount. the same three infoobjects i inlcuded the file structure in the global data as specified in the how to document
The flat file format is like this
Costelmnt Postingperiod Amount
XXXXX #
XXXXX 1 100
XXXXX 2 800
XXXXX 3 700
XXXXX 4 500
XXXXX 5 300
XXXXX 6 200
XXXXX 7 270
XXXXX 8 120
XXXXX 9 145
XXXXX 10 340
XXXXX 11 147
XXXXX 12 900
I successfully loaded above flat file in to BPS cube and it dispalyed in the layout also.
But users are requesting to load flatfile in the below format
Costelmnt Annual(PP=#) Jan(PP=1) Feb(PP=2) ........................................Dec(PP=12)
XXXXX Blank 100 800 900
Is it possible to load a flat file like this
They wants load a single row instead of 13 rows for each costelement
How to do this. Please suggest me if anybody accorss this requirment.
In the infocube we have got only one Info object 0FISCPER3(Posting period) and one 0AMOUNT(Amount)
do we need 13 Infobjects for each posting period and amount.
Is there any possiblity we can implement any user exit which we use in BEX Quer's
Please share your ideas on this.
Thanks in advance
Best regards
SSHi,
There are 2 ways to do this.
One is to change the structure of the cube to have 12 key figures for the 12 posting periods.
Another way is to write an ABAP Function Module to fetch the values from each record based on the posting period and store it in the cube for the corresponding characteristic. This way, you dont have to change the structure of the cube.
If this particular cube is not used anywhere else, I would suggest to change the structure itself.
Hope this helps.
Maybe you are looking for
-
Crystal Report 9 connectivity with WebLogic 10.3.5
Hello, Is the Crystal Report 9 certified with WebLogic 10.x? Currently WebLogic 8.x is in use. Trying to upgrade the WebLogic. Thanks
-
Editing Text in Dreamweaver Display View
I have just started using Dreamweaver CS4. In older versions of Dreamweaver, I'm used to seeing text in Display view and being able to edit the text directly in Display view, rather than having to edit text in Code view. But when I'm trying to edit t
-
During the process of buying a iPhoto book, the system ask the delivery contact information, where it doesn't accept the phone number. So I can't finish the order process! Is there a solution for this problem. Already try to create a new Apple ID wit
-
Premiere pro cs5.5 to final cut pro
Hello all, I have finished a project using premiere pro cs5.5. I edited footage I got from my canon t2i. 1080p, 23.9xx frames. I exported the movie using match sequence setting and I got a mpeg movie. Someone I work with needs to add some stuff to
-
Hi all, When i go to Right click --> Manage button and then Performance tab of any infocube i get 3 areas for concern. Check index which is Green for my infocubes. Check aggr index is also Green for my infocubes. Check Statistics --> This is where i