C_CADocumentReversal
Reverse Document
C_CADocumentReversal is a Consumption CDS View that provides data about "Reverse Document" in SAP S/4HANA. It reads from 1 data source (I_CADocumentHeader) and exposes 30 fields with key field CADocumentNumber. It has 5 associations to related views.
Data Sources (1)
| Source | Alias | Join Type |
|---|---|---|
| I_CADocumentHeader | I_CADocumentHeader | from |
Associations (5)
| Cardinality | Target | Alias | Condition |
|---|---|---|---|
| [1..1] | I_CADocumentType | _CADocumentType | $projection.CADocumentType = _CADocumentType.CADocumentType and $projection.CAApplicationArea = _CADocumentType.CAApplicationArea |
| [1..1] | I_CADocumentOriginCode | _CADocumentOriginCode | $projection.CADocumentOriginCode = _CADocumentOriginCode.CADocumentOriginCode |
| [0..1] | C_CAInvcgUserContact | _CreatedByContact | $projection.CreatedByUser = _CreatedByContact.ContactCardID |
| [0..1] | P_CADocumentIsBlocked | _CADocumentIsBlocked | $projection.CADocumentNumber = _CADocumentIsBlocked.CADocumentNumber |
| [1..1] | E_CADocumentHeader | _Extension | $projection.CADocumentNumber = _Extension.CADocumentNumber |
Annotations (18)
| Name | Value | Level | Field |
|---|---|---|---|
| AbapCatalog.sqlViewName | CCADOCREVERSE | view | |
| AbapCatalog.compiler.compareFilter | true | view | |
| AbapCatalog.preserveKey | true | view | |
| AccessControl.authorizationCheck | #CHECK | view | |
| AccessControl.personalData.blocking | #NOT_REQUIRED | view | |
| EndUserText.label | Reverse Document | view | |
| ClientHandling.algorithm | #SESSION_VARIABLE | view | |
| VDM.viewType | #CONSUMPTION | view | |
| UI.headerInfo.typeName | Document | view | |
| UI.headerInfo.typeNamePlural | Documents | view | |
| UI.headerInfo.title.value | CADocumentNumber | view | |
| ObjectModel.usageType.dataClass | #TRANSACTIONAL | view | |
| ObjectModel.usageType.serviceQuality | #D | view | |
| ObjectModel.usageType.sizeCategory | #XXL | view | |
| ObjectModel.updateEnabled | true | view | |
| Search.searchable | true | view | |
| UI.presentationVariant.sortOrder.by | CAPostingDate | view | |
| UI.presentationVariant.sortOrder.direction | #DESC | view |
Fields (30)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | CADocumentNumber | CADocumentNumber | Document Number | |
| CAReferenceDocument | Reference | |||
| CADocumentType | CADocumentType | Document Type | ||
| CADocumentTypeName | ||||
| CADocumentOriginCode | CADocumentOriginCode | Document Origin | ||
| CADocumentOriginCodeName | ||||
| CAReversedDocumentNumber | CAReversedDocumentNumber | Rev. Doc. For | ||
| CAReversalDocumentNumber | CAReversalDocumentNumber | Revers.document | ||
| CreatedByUser | CreatedByUser | User Name | ||
| CreatedByUserName | _CreatedByContact | FullName | Name | |
| CreationDate | CreationDate | Time Stamp | ||
| CAPostingDate | CAPostingDate | Posting Date | ||
| TransactionCurrency | TransactionCurrency | Transaction Currency | ||
| DocumentDate | DocumentDate | Document Date | ||
| CADocumentIsBlockedForUser | ||||
| AuthorizationGroup | _CADocumentIsBlocked | AuthorizationGroup | AuthorizGroup | |
| IsBusinessPurposeCompleted | _CADocumentIsBlocked | IsBusinessPurposeCompleted | Purpose Completed | |
| CANumberOfAuthorizationGroups | _CADocumentIsBlocked | CANumberOfAuthorizationGroups | ||
| CAClearingInformation | CAClearingInformation | Clearing Info | ||
| CAClearingDocIsExisting | ||||
| CAClarificationDocIsExisting | ||||
| CADocumentSemanticObject | ||||
| CADocRepetitionItemIsExisting | ||||
| CADocumentRepetitionItemIsOpen | ||||
| ChequeIsExisting | ||||
| CAAllRepetitionsAreReversed | ||||
| CAPostgToClrfctnAcctIsAllowed | ||||
| CAReconciliationKey | CAReconciliationKey | Reconcil. Key | ||
| CADocumentClass | CADocumentClass | Document Class | ||
| CAApplicationArea | CAApplicationArea | ApplicationArea |
Derived SQL interpretation, reconstructed from the parsed view metadata (data sources, associations, and field mappings). SAP annotations are omitted and the structure is reformulated as SQL — this is a functional approximation, not the verbatim SAP source.
-- Derived SQL interpretation of CDS view C_CADocumentReversal.
-- Reconstructed from parsed metadata (data sources, associations, fields).
-- SAP annotations are omitted and the structure is reformulated as SQL;
-- this is a functional approximation, not the verbatim SAP source. Some join
-- conditions may be unavailable and a few CDS constructs are kept as-is.
-- SQL view name: CCADOCREVERSE
CREATE VIEW C_CADocumentReversal AS
SELECT
CADocumentNumber,
cast (CAReferenceDocument as xblnr_gfn_kk preserving type) AS CAReferenceDocument,
CADocumentType,
_CADocumentType._Text[1:Language = $session.system_language].CADocumentTypeName AS CADocumentTypeName,
CADocumentOriginCode,
_CADocumentOriginCode._Text[1:Language = $session.system_language].CADocumentOriginCodeName AS CADocumentOriginCodeName,
CAReversedDocumentNumber,
CAReversalDocumentNumber,
CreatedByUser,
_CreatedByContact.FullName AS CreatedByUserName,
CreationDate,
CAPostingDate,
TransactionCurrency,
DocumentDate,
cast ('' as xfeld) AS CADocumentIsBlockedForUser,
_CADocumentIsBlocked.AuthorizationGroup AS AuthorizationGroup,
_CADocumentIsBlocked.IsBusinessPurposeCompleted AS IsBusinessPurposeCompleted,
_CADocumentIsBlocked.CANumberOfAuthorizationGroups AS CANumberOfAuthorizationGroups,
CAClearingInformation,
cast('' as xfeld) AS CAClearingDocIsExisting,
cast('' as xfeld) AS CAClarificationDocIsExisting,
cast('' as opbel_semobj_kk) AS CADocumentSemanticObject,
cast('' as xfeld) AS CADocRepetitionItemIsExisting,
cast('' as xfeld) AS CADocumentRepetitionItemIsOpen,
cast('' as xfeld) AS ChequeIsExisting,
cast('X' as xfeld) AS CAAllRepetitionsAreReversed,
cast('' as xfeld) AS CAPostgToClrfctnAcctIsAllowed,
CAReconciliationKey,
CADocumentClass,
CAApplicationArea
FROM I_CADocumentHeader
LEFT OUTER JOIN I_CADocumentType AS _CADocumentType ON CADocumentType = _CADocumentType.CADocumentType AND CAApplicationArea = _CADocumentType.CAApplicationArea -- association [1..1]
LEFT OUTER JOIN I_CADocumentOriginCode AS _CADocumentOriginCode ON CADocumentOriginCode = _CADocumentOriginCode.CADocumentOriginCode -- association [1..1]
LEFT OUTER JOIN C_CAInvcgUserContact AS _CreatedByContact ON CreatedByUser = _CreatedByContact.ContactCardID -- association [0..1]
LEFT OUTER JOIN P_CADocumentIsBlocked AS _CADocumentIsBlocked ON CADocumentNumber = _CADocumentIsBlocked.CADocumentNumber -- association [0..1]
LEFT OUTER JOIN E_CADocumentHeader AS _Extension ON CADocumentNumber = _Extension.CADocumentNumber -- association [1..1]
;
Learn More
- VDM (Virtual Data Model) in SAP S/4HANA Explained
- Types of CDS Views: Basic, Composite, Consumption, and Transactional
- CDS View Annotations — A Complete Guide
- What Is a CDS View in SAP S/4HANA?
- SAP Tables vs CDS Views — Key Differences
- Understanding Data Lineage in SAP S/4HANA
- CDS View Field Mapping and Associations
- Understanding the SAP S/4HANA Data Model
- CDS View Extensions and Custom Fields in SAP S/4HANA
- Released APIs and Stability Contracts in SAP S/4HANA
- BSEG to ACDOCA: The Universal Journal Migration
- Business Partner Migration: KNA1/LFA1 to BUT000
- Material Document Migration: MSEG/MKPF to MATDOC
- How to Find the Right CDS View for an SAP Table
- BW Extractor to CDS View Migration Guide
- S/4HANA CDS View Deprecation: What You Need to Know
- ABAP CDS View Tutorial — From Basics to Real-World Examples
- RAP and CDS Views — Building Transactional Apps in SAP S/4HANA
- Sales Document Status Migration: VBUP/VBUK Removal in S/4HANA
- CO Tables in S/4HANA: COEP, COBK, COSS, COSP to ACDOCA