2009 Mar 06 10:18 AM
Hallo
I want to update 4 fields of mara with function MATERIAL_MAINTAIN_DARK. can somebody give me a sample code.
Thanks a lot.
2009 Mar 06 10:26 AM
2009 Mar 06 10:34 AM
2009 Mar 06 10:29 AM
Hi,
Plesae find this code
CALL FUNCTION 'MATERIAL_MAINTAIN_DARK'
EXPORTING
flag_muss_pruefen = 'X'
* SPERRMODUS = 'E'
max_errors = 0
p_kz_no_warn = 'E'
kz_prf = ' '
kz_verw = 'X'
kz_aend = 'X'
kz_dispo = 'X'
kz_test = kz_test
no_database_update = ' '
call_mode = 'ACT'
* CALL_MODE2 = ' '
user = sy-uname
* SUPPRESS_ARRAY_READ = ' '
* FLG_MASS = 'X'
* DONT_PROCESS_HEADERS =
IMPORTING
matnr_last = g_f_matnr_last
number_errors_transaction = g_f_number_err
TABLES
amara_ueb = gt_mara_ueb
amakt_ueb = gt_makt_ueb
amarc_ueb = gt_marc_ueb
amard_ueb = gt_mard_ueb
* AMFHM_UEB =
* AMARM_UEB =
* AMEA1_UEB =
ambew_ueb = gt_mbew_ueb
asteu_ueb = gt_steu_ueb
* ASTMM_UEB =
* AMLGN_UEB =
amlgt_ueb = gt_mlgt_ueb
* AMPGD_UEB =
* AMPOP_UEB =
* AMVEG_UEB =
* AMVEU_UEB =
amvke_ueb = gt_mvke_ueb
* ALTX1_UEB =
* AMPRW_UEB =
* AMFIELDRES =
amerrdat = gt_errs
EXCEPTIONS
kstatus_empty = 1
tkstatus_empty = 2
t130m_error = 3
internal_error = 4
too_many_errors = 5
update_error = 6
error_propagate_header = 7
OTHERS = 8.
IF NOT ( sy-subrc IS INITIAL ).
ROLLBACK WORK.
ELSE.
COMMIT WORK.and check this link
http://www.sapnet.ru/viewtopic.php?t=457
Thanks and regards
Durga.K