How To Fix WS158 - You cannot cancel - accounting document does not exist for document &1


WS158 - Overview

  • Message type: E = Error

  • Message class: WS - Supplier Billing Document

  • Message number: 158

  • Message text: You cannot cancel - accounting document does not exist for document &1

  • Show details Hide details
  • What causes this issue?

    The accounting document for document &V1& does not exist in the system.

    System Response

    The system does not allow cancellation of document &V1&, as further
    errors would then arise when the accounting document is created for the
    cancellation document.

    How to fix this error?

    Create a credit memo for document &V1& or change the
    <DS:DE.WFARTS>settlement document type for the reversal document</> of
    settlement document document type &V2& so that a credit memo can be
    created for document &V1&.

    Error message extract from SAP system. Copyright SAP SE.


WS158 - Details

  • Certainly! Here's a detailed explanation for the SAP error message WS158:
    
    SAP Error Message WS158
    Message Text:
    You cannot cancel - accounting document does not exist for document &1
    
    Cause
    This error occurs when you attempt to cancel or reverse a document in SAP, but the system cannot find the corresponding accounting document linked to the original document number you provided.
    In SAP, many business documents (like invoices, goods movements, etc.) generate accounting documents that record the financial impact. When you try to cancel or reverse a document, SAP checks for the related accounting document to reverse the financial postings. If the accounting document is missing or was never created, the system throws this error.
    Common reasons include:
    
    The original document was created without generating an accounting document (e.g., a logistics document without financial impact).
    The accounting document was deleted or archived.
    You entered an incorrect document number or company code.
    The document belongs to a different fiscal year or company

    Already have an account? Login here!




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


WS158 - Related SAP Errors

Click on this link to search all SAP messages.


Rating
ERPlingo's SAP support assistant is amazing. Saves me countless hours trying to solve complex SAP issues myself. It's a real game changer!
Rate 1
Thomas Michael
SAP Consultant, Author & Speaker