Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Maintain the conversion factor for the alternative unit KG in Bapi

abdulgaffarmohd
Participant
0 Kudos
3,682

Hi all.,

I am using bapi BAPI_MATERIAL_SAVEDATA for creating material master.

For UOM conversion i am passing values in BAPI_MARM(UNITSOFMEASURE)

fields like ALT_UNIT,NUMERATOR,DENOMINATR .

and also passing PO_UNIT field. then also i am getting error like,

Maintain the conversion factor for the alternative unit KG

Regards,

Abdul .

4 REPLIES 4

Former Member
0 Kudos
1,517

Hi Abdul,

The units of measure have a Conversion Routine. Try, before assigning those values to MARM Structure, convert them to internal format.

Example:

Unit of measure PC has internal value ST. Do this for all the UoM you are using.



CALL FUNCTION 'CONVERSION_EXIT_CUNIT_INPUT'
  EXPORTING
    input                = uom
   LANGUAGE             = SY-LANGU
 IMPORTING
   OUTPUT               = uom_result
* EXCEPTIONS
*   UNIT_NOT_FOUND       = 1
*   OTHERS               = 2
          .
IF sy-subrc = 0.
 move uom_result to BAPI structure MARM.
ENDIF.
 

Hope this helps.

Ernesto

abdulgaffarmohd
Participant
0 Kudos
1,517

atually in the UOM-X structure there was an error while passing the values the values were passed reversal ...,solved by my self

0 Kudos
1,517

Hi,

I am using bapi BAPI_MATERIAL_SAVEDATA for creating material. I want to maintain conversion factors for

i) Purchase order unit in view purchasing

ii) unit of issue in view plantdata

How do I make entries in UNIT_OF_MEASURE and UNIT_OF_MEASUREX table to achieve this.

Appreciate your help!

Anyamar
Discoverer
0 Kudos
1,263

Hi, did you ever find the solution? I am having the same issues...