RWVLB004 is a standard Executable ABAP Report available within your SAP system (depending on your version and release level). Below is the basic information available for this SAP report including which OBJECTS it interacts with such as TABLES, FUNCTION MODULES, INCLUDES ETC. Also check out the submitted Comments related to this SAP report or see any standard documentation available.
If you would like to execute this report or see the full code listing simply enter RWVLB004 into the relevant SAP transactions such as SE38 or SE80
Below is a list of transaction codes which are relevant to this SAP report
WLB6 - Investment Buying Simulation
This report can be called from another progam/report simply by using the ABAP SUBMIT statement, see below for example ABAP code snipts of how to do this.
Selection Text: P1_CURCS = Current price
Selection Text: P1_DAYFR = Last day before price change
Selection Text: P1_DAYTO = Future price end date
Selection Text: P1_EKGRP = Purchasing group
Selection Text: P1_EKORG = Purchasing organization
Selection Text: P1_FUTCS = Future price
Selection Text: P1_KUNNR = Customer
Selection Text: P1_LIFNR = Vendor
Selection Text: P1_LKOST = Storage costs percentage
Selection Text: P1_MATNR = Material
Selection Text: P1_MEINS = Unit of measure for def. qty
Selection Text: P1_MENGE = Price simulation for def. qty
Selection Text: P1_PRWRT = Forecast value per week
Selection Text: P1_WERKS = Plant
Selection Text: P1_ZTAGX = Payment strategy
Selection Text: P_CUBECO = Office/facility expenses
Selection Text: P_DESROI = Target ROI
Selection Text: P_HANDCO = Ordering costs
Selection Text: P_TEDAYS = Payment target
Title: Investment Buying Simulation
Text Symbol: H02 = Current value New value Update?
Text Symbol: D04 = N
Text Symbol: D03 = Yes
Text Symbol: D02 = Save values?
Text Symbol: D01 = Confirmation box
Text Symbol: 640 = Required quantity rounded
Text Symbol: 630 = ROI required quantity
Text Symbol: 610 = Calculated ROI
Text Symbol: 606 = Standard PO
Text Symbol: 100 = Vendor
Text Symbol: 101 = =
Text Symbol: 110 = Purchasing organization
Text Symbol: 120 = Material
Text Symbol: 130 = Plant
Text Symbol: 200 = Volume
Text Symbol: 210 = Office/facility expenses
Text Symbol: 220 = Ordering costs
Text Symbol: 230 = Base unit of measure
No INCLUDES are used within this REPORT code!
No SAP DATABASE tables are accessed within this REPORT code!
VENDOR_MASTER_DATA_SELECT_12 CALL FUNCTION 'VENDOR_MASTER_DATA_SELECT_12' EXPORTING pi_lifnr = p1_lifnr pi_ekorg = p1_ekorg IMPORTING pe_lfm1 = lfm1 EXCEPTIONS no_entry_found = 1 OTHERS = 2.
LOCATION_GET_PLANT_CURRENCY CALL FUNCTION 'LOCATION_GET_PLANT_CURRENCY' EXPORTING i_werks = p1_werks IMPORTING o_waers = l_currency_site EXCEPTIONS invalid_plant = 1 valuation_area_not_found = 2 bukrs_not_found = 3 no_currency_available = 4 OTHERS = 5.
CURRENCY_CONVERTING_FACTOR CALL FUNCTION 'CURRENCY_CONVERTING_FACTOR' EXPORTING currency = l_currency IMPORTING factor = l_cur_factor_vend EXCEPTIONS too_many_decimals = 1 OTHERS = 2.
CURRENCY_CONVERTING_FACTOR CALL FUNCTION 'CURRENCY_CONVERTING_FACTOR' EXPORTING currency = l_currency_site IMPORTING factor = l_cur_factor_site EXCEPTIONS too_many_decimals = 1 OTHERS = 2.
MARC_SINGLE_READ CALL FUNCTION 'MARC_SINGLE_READ' EXPORTING matnr = p1_matnr werks = p1_werks IMPORTING wmarc = marc EXCEPTIONS lock_on_marc = 1 lock_system_error = 2 wrong_call = 3 not_found = 4 OTHERS = 5.
T001W_SINGLE_READ CALL FUNCTION 'T001W_SINGLE_READ' EXPORTING t001w_werks = p1_werks IMPORTING wt001w = t001w EXCEPTIONS not_found = 1 OTHERS = 2.
WLB_READ_ROI_PARAMETER CALL FUNCTION 'WLB_READ_ROI_PARAMETER' EXPORTING i_wlbtdstrat = p1_ztagx TABLES ie_t_roi_parms = itab_roi EXCEPTIONS OTHERS = 1.
CONVERT_TO_LOCAL_CURRENCY CALL FUNCTION 'CONVERT_TO_LOCAL_CURRENCY' EXPORTING date = sy-datlo foreign_amount = itab_roi-handling_cost foreign_currency = l_currency_site local_currency = l_currency * RATE = 0 * TYPE_OF_RATE = 'M' * READ_TCURR = 'X' IMPORTING local_amount = l_handco EXCEPTIONS no_rate_found = 1 overflow = 2 no_factors_found = 3 no_spread_found = 4 derived_2_times = 5 OTHERS = 6 .
CONVERT_TO_LOCAL_CURRENCY CALL FUNCTION 'CONVERT_TO_LOCAL_CURRENCY' EXPORTING date = sy-datlo foreign_amount = itab_roi-cube_cost foreign_currency = l_currency_site local_currency = l_currency * RATE = 0 * TYPE_OF_RATE = 'M' * READ_TCURR = 'X' IMPORTING local_amount = l_cubeco EXCEPTIONS no_rate_found = 1 overflow = 2 no_factors_found = 3 no_spread_found = 4 derived_2_times = 5 OTHERS = 6 .
WLB_CALCULATE_ROI CALL FUNCTION 'WLB_CALCULATE_ROI' EXPORTING date_from = p1_dayfr date_to = p1_dayto TABLES i_t_roi = itab_roi e_t_roi = itab_roi_e EXCEPTIONS OTHERS = 0.
WLB_CALCULATE_FORECAST * CALL FUNCTION 'WLB_CALCULATE_FORECAST' * EXPORTING * i_forecast_date = p1_dayfr * TABLES * t_i_articles = l_t_avg_fcst * EXCEPTIONS * OTHERS = 0.
WLB3_CALC_FORECAST CALL FUNCTION 'WLB3_CALC_FORECAST' EXPORTING * I_WERKS = i_forecast_date = p1_dayfr * I_CURRENT_DATE = * I_ONLY_FOR_THIS_DAY = * i_nr_of_periods = TABLES * CH_T_FORECAST = ch_t_articles = l_t_avg_fcst * E_T_FORECASTS = * e_t_all_forecasts = EXCEPTIONS bad_params = 1 error = 2 error_message = 99 OTHERS = 98 .
T001W_SINGLE_READ CALL FUNCTION 'T001W_SINGLE_READ' EXPORTING t001w_werks = itab_roi_e-werks IMPORTING wt001w = t001w EXCEPTIONS not_found = 1 OTHERS = 2.
MD_EINZELRUNDUNG * CALL FUNCTION 'MD_EINZELRUNDUNG' * EXPORTING * i_opcode = '1' "like PO-rounding * i_matnr = itab_roi_e-matnr * i_menge = t_menge * i_meins = itab_roi_e-meins * i_werk = itab_roi_e-werks * i_lifnr = itab_roi_e-lifnr * IMPORTING **@001-Anfang ** Nehme die gerundete Menge in der ursprünglichen Mengeneinheit ** E_LMENGE = T_MENGE ** E_LOGME = ITAB_ROI_E-MEINS * e_menge = t_menge **@001-Ende * EXCEPTIONS * invalid_opcode = 1 * no_purchase_org = 2 * rdpr_not_found = 3 * material_not_found = 4 * meinh_not_found = 5 * bad_params = 6 * debitor_not_found = 7 * no_round = 8 * OTHERS = 9.
MD_SINGLE_ROUNDING CALL FUNCTION 'MD_SINGLE_ROUNDING' EXPORTING i_s_general = l_s_general IMPORTING e_s_results = l_s_results EXCEPTIONS invalid_opcode = 1 no_purchase_org = 2 rdpr_not_found = 3 material_not_found = 4 meinh_not_found = 5 bad_params = 6 debitor_not_found = 7 no_round = 8 rdprf_not_found = 9 error = 10 OTHERS = 99.
ME_PO_PRICE_SIMULATION CALL FUNCTION 'ME_PO_PRICE_SIMULATION' EXPORTING i_print_list = ' ' i_pricing_data = i_simul_po TABLES t_komp = l_t_komp EXCEPTIONS error_create_po = 1 OTHERS = 2.
WLB_INVESTMENT_BUY_CEATE_PREQ CALL FUNCTION 'WLB_INVESTMENT_BUY_CEATE_PREQ' EXPORTING i_wlb0001 = l_wlb0001 TABLES i_t_pr = l_t_pr i_t_inv_buy = l_t_invest_buy EXCEPTIONS internal_error = 1 document_not_created = 2 logging_not_written = 3 error_message = 4 OTHERS = 5.
MATERIAL_UNIT_CONVERSION CALL FUNCTION 'MATERIAL_UNIT_CONVERSION' EXPORTING input = menge kzmeinh = 'X' matnr = mara-matnr meinh = von_me meins = mara-meins type_umr = '3' IMPORTING addko = l_addko output = menge umren = l_umren umrez = l_umrez EXCEPTIONS conversion_not_found = 1 input_invalid = 2 material_not_found = 3 meinh_not_found = 4 meins_missing = 5 no_meinh = 6 output_invalid = 7 overflow = 8 error_message = 99 OTHERS = 9.
Although this basic information may have limited use it does provide an easy to find location to store any knowledge about this program/report.
The contribute/comments section below therefore offer's an opportunity for anyone to add additional information. This can be anything from useful hints, tips and screen shots to relevant SAP notes or anything else you feel is relevant to this report.
This will then be available for everyone to easily find by simply searching on the report name RWVLB004 or its description.