Stop googling SAP errors. Use our Free Essentials plan instead - no credit card needed. Start Now

Close

How To Fix WE240 - EAN with determined check digit: &


SAP Error Message - Details

  • Message type: E = Error

  • Message class: WE - Messages for EAN Customizing and for EAN management in MM_BD

  • Message number: 240

  • Message text: EAN with determined check digit: &

  • Show details Hide details


  • Self-Explanatory Message

    Since SAP believes that this specific error message is 'self-explanatory,' no more information has been given.The majority of messages in the SAP system have a message text, however this is frequently insufficient to comprehend or resolve the problem.

    To make things easier, more detailed information is frequently added to describe the issue, how to fix it, and the necessary steps or configuration modifications.

    Unfortunately, there isn't any extra information in this error notice.



    What else can you do?

    First, use our AnswerBot below to get a possible cause and solution (requires a premium subscription).

    Also, review the in-depth Common Questions & Answers listed below; you could discover a solution there or be able to connect with others who have faced similar challenges.

    You can also try searching the SAP support portal (support.sap.com) but you need a special user ID to access it. It is possible that an SAP support note exists that provides additional details about the mistake or even steps for fixing it.


Smart SAP Assistant

  • What is the cause and solution for SAP error message WE240 - EAN with determined check digit: & ?

    SAP Error Message:
    WE240 – "EAN with determined check digit: &"


    Meaning / Cause:

    The error message WE240 occurs during IDoc processing or EDI message handling when the system detects an EAN (European Article Number) or GTIN (Global Trade Item Number) with an incorrect or invalid check digit.

    • The EAN/GTIN is a barcode number used to uniquely identify products.
    • The last digit of the EAN is a check digit, calculated from the preceding digits using a specific algorithm (modulus 10).
    • If the check digit does not match the calculated value, SAP raises this error.
    • The placeholder "&" in the message is replaced by the incorrect check digit found or the problematic EAN number.

    Technical Background:

    • The check digit is calculated using the standard EAN/GTIN algorithm:
      1. Sum all digits in odd positions (from right to left).
      2. Sum all digits in even positions and multiply by 3.
      3. Add the two sums.
      4. The check digit is the number that must be added to this total to reach the next multiple of 10.
    • If the provided check digit does not match this calculation, the EAN is considered invalid.

    When does this error occur?

    • During inbound IDoc processing (e.g., ORDERS, INVOIC, DESADV) when the system validates EANs.
    • During outbound message generation if the system tries to validate or generate EANs.
    • When EANs are maintained or validated in material master or related master data.
    • During EDI inbound processing if the EAN number in the message is incorrect.

    Solution / How to fix:

    1. Check the EAN number:

      • Verify the EAN number in the source data (e.g., IDoc segment, EDI message, material master).
      • Confirm that the EAN number is correct and complete (usually 8, 12, 13, or 14 digits).
    2. Recalculate the check digit:

      • Use an EAN check digit calculator (many online tools available) to verify the correct check digit.
      • Correct the EAN number in the source system or master data if the check digit is wrong.
    3. Correct the data in SAP:

      • If the EAN is stored in material master (transaction MM02), update the EAN/GTIN with the correct number.
      • If the EAN comes from an external system or EDI partner, request corrected data.
    4. Check IDoc or EDI message:

      • If the error occurs during IDoc inbound processing, check the inbound IDoc segments (e.g., E1EDP01 for item data).
      • Correct the EAN in the sending system or map the correct EAN in the interface.
    5. Disable check digit validation (not recommended):

      • In some cases, if validation is not required, you can disable check digit validation in the system.
      • This is generally not recommended as it may lead to data inconsistencies.

    Related SAP Notes / References:

    • SAP Note 108011 – "EAN check digit validation"
    • SAP Help on EAN/GTIN validation in IDoc processing
    • SAP standard function modules for EAN check digit calculation, e.g., EAN_CHECK_DIGIT_CALCULATE

    Summary:

    • Cause: Invalid EAN number with incorrect check digit.
    • Solution: Verify and correct the EAN number/check digit in the source data or master data.
    • Check: Use standard EAN check digit calculation to validate.
    • Avoid: Disabling validation unless absolutely necessary.

    If you provide the exact EAN number or IDoc segment, I can help you calculate the correct check digit or guide you further.

    • Do you have any question about this error?


      Upgrade now to chat with this error.


Instant HelpGet instant SAP help. Sign up for our Free Essentials Plan.


Related SAP Error Messages

Click the links below to see the following related messages:

Click on this link to search all SAP messages.


Rating
ERPlingo simplifies finding the accurate answers to SAP message errors. I now use every week. A must have tool for anyone working with SAP! Highly recommended!
Rate 1
Kent Bettisworth
Executive SAP Consultant