ESH_N_MATLDOC
Anchor view -MATLDOC
ESH_N_MATLDOC is a CDS View that provides data about "Anchor view -MATLDOC" in SAP S/4HANA. It reads from 1 data source (I_MaterialDocumentHeader_2) and exposes 33 fields with key fields MaterialDocument, MaterialDocumentYear. Part of development package BSESH_MM_IM_HANA_CONTENT.
Data Sources (1)
| Source | Alias | Join Type |
|---|---|---|
| I_MaterialDocumentHeader_2 | I_MaterialDocumentHeader_2 | from |
Parameters (1)
| Name | Type | Default |
|---|---|---|
| P_Language | abap.lang |
Annotations (7)
| Name | Value | Level | Field |
|---|---|---|---|
| AccessControl.authorizationCheck | #CHECK | view | |
| ObjectModel.usageType.serviceQuality | #B | view | |
| ObjectModel.usageType.sizeCategory | #XXL | view | |
| ObjectModel.usageType.dataClass | #TRANSACTIONAL | view | |
| ClientHandling.algorithm | #SESSION_VARIABLE | view | |
| AccessControl.personalData.blocking | #BLOCKED_DATA_EXCLUDED | view | |
| AbapCatalog.sqlViewName | ESH_L_MATLDOC | view |
Fields (33)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | MaterialDocument | MaterialDocument | Material Doc. | |
| KEY | MaterialDocumentYear | MaterialDocumentYear | Material Document Year | |
| AccountingDocumentType | AccountingDocumentType | Journal Entry Type | ||
| AccountingDocumentTypeName | ||||
| BillOfLading | BillOfLading | |||
| CompanyCode | _MaterialDocumentItem | CompanyCode | Receiver Company Code | |
| CompanyCodeName | ||||
| CreatedByUser | CreatedByUser | User Name | ||
| CreationDate | CreationDate | Time Stamp | ||
| CreationTime | CreationTime | Time of Change | ||
| DeliveryDocument | DeliveryDocument | Outbound Delivery | ||
| DocumentDate | DocumentDate | Journal Entry Date | ||
| GoodsMovementType | _MaterialDocumentItem | GoodsMovementType | Movement Type | |
| GoodsMovementTypeName | ||||
| InventoryTransactionType | InventoryTransactionType | Trans. Ev. Type | ||
| InventoryTransactionTypeText | ||||
| IsAutomaticallyCreated | _MaterialDocumentItem | IsAutomaticallyCreated | Is Automatically Created | |
| IssuingOrReceivingPlant | _MaterialDocumentItem | IssuingOrReceivingPlant | Transfer Plant | |
| IssuingOrReceivingStorageLoc | _MaterialDocumentItem | IssuingOrReceivingStorageLoc | Receiving SLoc. | |
| Material | _MaterialDocumentItem | Material | Vehicle Model | |
| MaterialDocumentHeaderText | MaterialDocumentHeaderText | |||
| MaterialDocumentItem | _MaterialDocumentItem | MaterialDocumentItem | Material Document Item | |
| MaterialDocumentItemText | _MaterialDocumentItem | MaterialDocumentItemText | Text | |
| MaterialGroup | ||||
| MaterialGroupName | ||||
| MaterialName | ||||
| Plant | _MaterialDocumentItem | Plant | Valuation Area | |
| PlantName | ||||
| PostingDate | PostingDate | Posting Date for GR | ||
| ReferenceDocument | ReferenceDocument | Reference Document | ||
| StorageLocation | _MaterialDocumentItem | StorageLocation | StorageLocation | |
| StorageLocationName | ||||
| UserDescription | _User | UserDescription | Full Name |
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 ESH_N_MATLDOC.
-- 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: ESH_L_MATLDOC
-- Parameters: P_Language : abap.lang
CREATE VIEW ESH_N_MATLDOC AS
SELECT
MaterialDocument,
MaterialDocumentYear,
AccountingDocumentType,
_AccountingDocumentType._Text[1: Language = $parameters. P_Language].AccountingDocumentTypeName AS AccountingDocumentTypeName,
BillOfLading,
_MaterialDocumentItem.CompanyCode AS CompanyCode,
_MaterialDocumentItem._CompanyCode.CompanyCodeName AS CompanyCodeName,
CreatedByUser,
CreationDate,
CreationTime,
DeliveryDocument,
DocumentDate,
_MaterialDocumentItem.GoodsMovementType AS GoodsMovementType,
_MaterialDocumentItem._GoodsMvtTypeBySpclStkIndT[1: Language = $parameters. P_Language].GoodsMovementTypeName AS GoodsMovementTypeName,
InventoryTransactionType,
_InventoryTransactionType._Text[1: Language = $parameters. P_Language].InventoryTransactionTypeText AS InventoryTransactionTypeText,
_MaterialDocumentItem.IsAutomaticallyCreated AS IsAutomaticallyCreated,
_MaterialDocumentItem.IssuingOrReceivingPlant AS IssuingOrReceivingPlant,
_MaterialDocumentItem.IssuingOrReceivingStorageLoc AS IssuingOrReceivingStorageLoc,
_MaterialDocumentItem.Material AS Material,
MaterialDocumentHeaderText,
_MaterialDocumentItem.MaterialDocumentItem AS MaterialDocumentItem,
_MaterialDocumentItem.MaterialDocumentItemText AS MaterialDocumentItemText,
_MaterialDocumentItem._Material._MaterialGroup.MaterialGroup AS MaterialGroup,
_MaterialDocumentItem._Material._MaterialGroup._Text[1: Language = $parameters. P_Language].MaterialGroupName AS MaterialGroupName,
_MaterialDocumentItem._Material._Text[1: Language = $parameters. P_Language].MaterialName AS MaterialName,
_MaterialDocumentItem.Plant AS Plant,
_MaterialDocumentItem._Plant.PlantName AS PlantName,
PostingDate,
ReferenceDocument,
_MaterialDocumentItem.StorageLocation AS StorageLocation,
_MaterialDocumentItem._StorageLocation.StorageLocationName AS StorageLocationName,
_User.UserDescription AS UserDescription
FROM I_MaterialDocumentHeader_2
;
Learn More
- CDS View Annotations — A Complete Guide
- What Is a CDS View in SAP S/4HANA?
- Types of CDS Views: Basic, Composite, Consumption, and Transactional
- SAP Tables vs CDS Views — Key Differences
- Understanding Data Lineage in SAP S/4HANA
- VDM (Virtual Data Model) in SAP S/4HANA Explained
- 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