2010 Aug 17 6:45 PM
Hello all,
Does anyone know how I can make an update/insert into MLAN and make the changes appear on MM04?
I'm trying bapi_material_savedata but it's always giving me errors as "Tax category LCFR does not define classification 1" or "Tax category does not define classification 1"
MOVE: MLAN-ALAND TO LT_BAPI_MLAN-DEPCOUNTRY,
MLAN-TAXIM TO LT_BAPI_MLAN-TAX_IND,
lv_class TO LT_BAPI_MLAN-TAX_TYPE_1,
MLAN-TAXM1 TO LT_BAPI_MLAN-TAXCLASS_1,
lv_class TO LT_BAPI_MLAN-TAX_TYPE_2,
MLAN-TAXM2 TO LT_BAPI_MLAN-TAXCLASS_2.
APPEND LT_BAPI_MLAN.
CALL FUNCTION 'BAPI_MATERIAL_SAVEDATA'
EXPORTING
HEADDATA = LT_BAPI_MM
SALESDATA = LT_BAPI_MVKE
SALESDATAX = LT_BAPI_MVKEX
IMPORTING
RETURN = LT_BAPIRET
TABLES
MATERIALDESCRIPTION = LT_MAT_DESC
TAXCLASSIFICATIONS = LT_BAPI_MLAN
RETURNMESSAGES = LT_RET_MSG.
2010 Aug 17 9:27 PM
Why don't you fix the configuration issue instead (or use the correct value)?
SD -> Basic functions -> Taxes -> Define Tax Relevancy...
Hello all,
Does anyone know how I can make an update/insert into MLAN and make the changes appear on MM04?
I'm trying bapi_material_savedata but it's always giving me errors as "Tax category LCFR does not define classification 1" or "Tax category does not define classification 1"
MOVE: MLAN-ALAND TO LT_BAPI_MLAN-DEPCOUNTRY,
MLAN-TAXIM TO LT_BAPI_MLAN-TAX_IND,
lv_class TO LT_BAPI_MLAN-TAX_TYPE_1,
MLAN-TAXM1 TO LT_BAPI_MLAN-TAXCLASS_1,
lv_class TO LT_BAPI_MLAN-TAX_TYPE_2,
MLAN-TAXM2 TO LT_BAPI_MLAN-TAXCLASS_2.
APPEND LT_BAPI_MLAN.
CALL FUNCTION 'BAPI_MATERIAL_SAVEDATA'
EXPORTING
HEADDATA = LT_BAPI_MM
SALESDATA = LT_BAPI_MVKE
SALESDATAX = LT_BAPI_MVKEX
IMPORTING
RETURN = LT_BAPIRET
TABLES
MATERIALDESCRIPTION = LT_MAT_DESC
TAXCLASSIFICATIONS = LT_BAPI_MLAN
RETURNMESSAGES = LT_RET_MSG.
2010 Aug 17 9:27 PM
Why don't you fix the configuration issue instead (or use the correct value)?
SD -> Basic functions -> Taxes -> Define Tax Relevancy...
2010 Aug 17 9:36 PM
The idea is to have a report that corrects the values of the taxes for a list of material automatically.
2010 Aug 17 9:55 PM
Of course...but the combination of values that you're trying to use isn't configured in your system, so either the config is missing or your BAPI call is wrong. This is why we don't do direct updates, so we don't bypass validations like this. Have you reviewed the configuration or debugged to understand the source of the error message?
2010 Aug 17 10:42 PM
yes...but I was not sure if the problem was customization! I don't even know if totaly customizing this is an option to the client! Before, the customer was doing a direct update!
Do you know here I can customize this, so that I don't get the error?
2010 Aug 18 2:02 PM
Yes, it is possible - I gave you the IMG path in my previous post - just choose 'Material Taxes' after following the path. I can't comment on whether the combination makes sense for your implementation though, as I'm not familiar with LCFR.