FAC_DART_Z3_MATLINVTRY_LINEITM
Material Inventory Line Item
FAC_DART_Z3_MATLINVTRY_LINEITM is a CDS View that provides data about "Material Inventory Line Item" in SAP S/4HANA. It reads from 2 data sources (FAC_DART_Z3_MI_LINEITEM_BASE, I_LedgerCompanyCodeCrcyRoles) and exposes 46 fields with key fields SourceLedger, CompanyCode, Ledger, GLAccount, FiscalYear. It has 5 associations to related views.
Data Sources (2)
| Source | Alias | Join Type |
|---|---|---|
| FAC_DART_Z3_MI_LINEITEM_BASE | FAC_DART_Z3_MI_LINEITEM_BASE | from |
| I_LedgerCompanyCodeCrcyRoles | I_LedgerCompanyCodeCrcyRoles | inner |
Parameters (3)
| Name | Type | Default |
|---|---|---|
| P_FiscalYear | fins_gjahr | |
| P_FromFiscalPeriod | fins_fagl_fiscper_from | |
| P_ToFiscalPeriod | fins_fagl_fiscper_to |
Associations (5)
| Cardinality | Target | Alias | Condition |
|---|---|---|---|
| [0..1] | I_AccountingDocumentType | _AccountingDocumentType | $projection.AccountingDocumentType = _AccountingDocumentType.AccountingDocumentType |
| [1] | I_JournalEntry | _JournalEntry | $projection.CompanyCode = _JournalEntry.CompanyCode and $projection.FiscalYear = _JournalEntry.FiscalYear and $projection.AccountingDocument = _JournalEntry.AccountingDocument |
| [0..1] | I_ReferenceDocumentType | _ReferenceDocumentType | $projection.ReferenceDocumentType = _ReferenceDocumentType.ReferenceDocumentType |
| [0..1] | I_FiscalPeriodForVariant | _FromFiscalYearPeriod | _FromFiscalYearPeriod.FiscalYearVariant = $projection.FiscalYearVariant and _FromFiscalYearPeriod.FiscalYear = $parameters.P_FiscalYear and _FromFiscalYearPeriod.FiscalPeriod = $parameters.P_FromFiscalPeriod |
| [0..1] | I_FiscalPeriodForVariant | _ToFiscalYearPeriod | _ToFiscalYearPeriod.FiscalYearVariant = $projection.FiscalYearVariant and _ToFiscalYearPeriod.FiscalYear = $parameters.P_FiscalYear and _ToFiscalYearPeriod.FiscalPeriod = $parameters.P_ToFiscalPeriod |
Annotations (8)
| Name | Value | Level | Field |
|---|---|---|---|
| AbapCatalog.sqlViewName | FAC_DZMILNITM | view | |
| AbapCatalog.compiler.compareFilter | true | view | |
| AbapCatalog.preserveKey | true | view | |
| AccessControl.authorizationCheck | #CHECK | view | |
| ObjectModel.usageType.serviceQuality | #D | view | |
| ObjectModel.usageType.sizeCategory | #XL | view | |
| ObjectModel.usageType.dataClass | #MIXED | view | |
| EndUserText.label | Material Inventory Line Item | view |
Fields (46)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | SourceLedger | SourceLedger | ||
| KEY | CompanyCode | FAC_DART_Z3_MI_LINEITEM_BASE | CompanyCode | |
| KEY | Ledger | FAC_DART_Z3_MI_LINEITEM_BASE | Ledger | |
| KEY | GLAccount | GLAccount | ||
| KEY | FiscalYear | FiscalYear | ||
| KEY | AccountingDocument | AccountingDocument | ||
| KEY | LedgerGLLineItem | LedgerGLLineItem | ||
| KEY | Material | Material | ||
| FiscalYearVariant | I_LedgerCompanyCodeCrcyRoles | FiscalYearVariant | ||
| ChartOfAccounts | FAC_DART_Z3_MI_LINEITEM_BASE | ChartOfAccounts | ||
| GLAccountLongName | ||||
| MaterialName | ||||
| MaterialGroup | MaterialGroup | |||
| MaterialGroupName | ||||
| PostingDate | PostingDate | |||
| Plant | Plant | |||
| PlantName | _Plant | PlantName | ||
| FiscalPeriod | FiscalPeriod | |||
| AccountingDocumentCategory | _JournalEntry | AccountingDocumentCategory | ||
| AccountingDocumentType | AccountingDocumentType | |||
| AccountingDocumentTypeName | ||||
| OriginalReferenceDocument | _JournalEntry | OriginalReferenceDocument | ||
| ReferenceDocumentType | ReferenceDocumentType | |||
| ReferenceDocumentTypeName | ||||
| AmountInCompanyCodeCurrency | AmountInCompanyCodeCurrency | |||
| CompanyCodeCurrency | CompanyCodeCurrency | |||
| InventoryQty | InventoryQty | |||
| BaseUnit | BaseUnit | |||
| ValuationArea | ValuationArea | |||
| _CompanyCode | FAC_DART_Z3_MI_LINEITEM_BASE | _CompanyCode | ||
| MaterialDocument | MaterialDocument | |||
| MaterialDocumentYear | MaterialDocumentYear | |||
| InventoryTransactionType | _MaterialDocumentHeader | InventoryTransactionType | ||
| DocumentDate | _JournalEntry | DocumentDate | ||
| AccountingDocumentHeaderText | _JournalEntry | AccountingDocumentHeaderText | ||
| AccountingDocumentCreationDate | _JournalEntry | AccountingDocumentCreationDate | ||
| AccountingDocCreatedByUser | _JournalEntry | AccountingDocCreatedByUser | ||
| _GLAccountInChartOfAccounts | _GLAccountInChartOfAccounts | |||
| _JournalEntry | _JournalEntry | |||
| _Material | _Material | |||
| _ChartOfAccounts | FAC_DART_Z3_MI_LINEITEM_BASE | _ChartOfAccounts | ||
| _MaterialGroup | _MaterialGroup | |||
| _Plant | _Plant | |||
| _AccountingDocumentType | _AccountingDocumentType | |||
| _ReferenceDocumentType | _ReferenceDocumentType | |||
| _MaterialDocumentHeader | _MaterialDocumentHeader |
@AbapCatalog.sqlViewName: 'FAC_DZMILNITM'
@AbapCatalog.compiler.compareFilter: true
@AbapCatalog.preserveKey: true
@AccessControl.authorizationCheck: #CHECK
@ObjectModel.usageType.serviceQuality: #D
@ObjectModel.usageType.sizeCategory: #XL
@ObjectModel.usageType.dataClass: #MIXED
@EndUserText.label: 'Material Inventory Line Item'
define view FAC_DART_Z3_MATLINVTRY_LINEITM
with parameters
P_FiscalYear : fins_gjahr,
@EndUserText.label: 'From Fiscal Period'
P_FromFiscalPeriod : fins_fagl_fiscper_from,
@EndUserText.label: 'To Fiscal Period'
P_ToFiscalPeriod : fins_fagl_fiscper_to
as select from FAC_DART_Z3_MI_LINEITEM_BASE
inner join I_LedgerCompanyCodeCrcyRoles on FAC_DART_Z3_MI_LINEITEM_BASE.CompanyCode = I_LedgerCompanyCodeCrcyRoles.CompanyCode
and FAC_DART_Z3_MI_LINEITEM_BASE.Ledger = I_LedgerCompanyCodeCrcyRoles.Ledger
association [0..1] to I_AccountingDocumentType as _AccountingDocumentType on $projection.AccountingDocumentType = _AccountingDocumentType.AccountingDocumentType
association [1] to I_JournalEntry as _JournalEntry on $projection.CompanyCode = _JournalEntry.CompanyCode
and $projection.FiscalYear = _JournalEntry.FiscalYear
and $projection.AccountingDocument = _JournalEntry.AccountingDocument
association [0..1] to I_ReferenceDocumentType as _ReferenceDocumentType on $projection.ReferenceDocumentType = _ReferenceDocumentType.ReferenceDocumentType
association [0..1] to I_FiscalPeriodForVariant as _FromFiscalYearPeriod on _FromFiscalYearPeriod.FiscalYearVariant = $projection.FiscalYearVariant
and _FromFiscalYearPeriod.FiscalYear = $parameters.P_FiscalYear
and _FromFiscalYearPeriod.FiscalPeriod = $parameters.P_FromFiscalPeriod
association [0..1] to I_FiscalPeriodForVariant as _ToFiscalYearPeriod on _ToFiscalYearPeriod.FiscalYearVariant = $projection.FiscalYearVariant
and _ToFiscalYearPeriod.FiscalYear = $parameters.P_FiscalYear
and _ToFiscalYearPeriod.FiscalPeriod = $parameters.P_ToFiscalPeriod
{
key SourceLedger,
@ObjectModel.foreignKey.association: '_CompanyCode'
key FAC_DART_Z3_MI_LINEITEM_BASE.CompanyCode,
key FAC_DART_Z3_MI_LINEITEM_BASE.Ledger,
@ObjectModel.foreignKey.association: '_GLAccountInChartOfAccounts'
key GLAccount,
@Semantics.fiscal.year: true
key FiscalYear,
@ObjectModel.foreignKey.association: '_JournalEntry'
key AccountingDocument,
key LedgerGLLineItem,
@ObjectModel.foreignKey.association: '_Material'
key Material,
I_LedgerCompanyCodeCrcyRoles.FiscalYearVariant as FiscalYearVariant,
@ObjectModel.foreignKey.association: '_ChartOfAccounts'
FAC_DART_Z3_MI_LINEITEM_BASE.ChartOfAccounts,
_GLAccountInChartOfAccounts._Text[1: Language = $session.system_language].GLAccountLongName,
_Material._Text[1: Language = $session.system_language].MaterialName,
@ObjectModel.foreignKey.association: '_MaterialGroup'
MaterialGroup,
_MaterialGroup._Text[1: Language = $session.system_language].MaterialGroupName,
PostingDate,
@ObjectModel.foreignKey.association: '_Plant'
Plant,
_Plant.PlantName,
@Semantics.fiscal.period: true
FiscalPeriod,
_JournalEntry.AccountingDocumentCategory as AccountingDocumentCategory,
@ObjectModel.foreignKey.association: '_AccountingDocumentType'
AccountingDocumentType,
_AccountingDocumentType._Text[1: Language = $session.system_language].AccountingDocumentTypeName,
_JournalEntry.OriginalReferenceDocument,
@ObjectModel.foreignKey.association: '_ReferenceDocumentType'
ReferenceDocumentType,
_ReferenceDocumentType._Text[1: Language = $session.system_language ].ReferenceDocumentTypeName,
@DefaultAggregation: #SUM
@Semantics: { amount : {currencyCode: 'CompanyCodeCurrency'} }
AmountInCompanyCodeCurrency,
@Semantics.currencyCode:true
CompanyCodeCurrency,
@DefaultAggregation: #SUM
@Semantics: { quantity : {unitOfMeasure: 'BaseUnit'} }
InventoryQty,
@Semantics.unitOfMeasure:true
BaseUnit,
ValuationArea,
FAC_DART_Z3_MI_LINEITEM_BASE._CompanyCode,
MaterialDocument,
MaterialDocumentYear,
_MaterialDocumentHeader.InventoryTransactionType,
_JournalEntry.DocumentDate,
_JournalEntry.AccountingDocumentHeaderText,
_JournalEntry.AccountingDocumentCreationDate,
_JournalEntry.AccountingDocCreatedByUser,
_GLAccountInChartOfAccounts,
_JournalEntry,
_Material,
FAC_DART_Z3_MI_LINEITEM_BASE._ChartOfAccounts,
_MaterialGroup,
_Plant,
_AccountingDocumentType,
_ReferenceDocumentType,
_MaterialDocumentHeader
}
where
_JournalEntry.AccountingDocumentCategory <> 'D'
and _JournalEntry.AccountingDocumentCategory <> 'M'
and _JournalEntry.AccountingDocumentCategory <> 'S'
and _JournalEntry.AccountingDocumentCategory <> 'V'
and _JournalEntry.AccountingDocumentCategory <> 'W'
and _JournalEntry.AccountingDocumentCategory <> 'Z'
and _JournalEntry.AccountingDocumentCategory <> 'T'
and PostingDate <= _ToFiscalYearPeriod.FiscalPeriodEndDate
and PostingDate >= _FromFiscalYearPeriod.FiscalPeriodStartDate
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"FAC_DART_Z3_MI_LINEITEM_BASE",
"I_ACCOUNTINGDOCUMENTTYPE",
"I_ACCOUNTINGDOCUMENTTYPETEXT",
"I_FISCALPERIODFORVARIANT",
"I_GLACCOUNTINCHARTOFACCOUNTS",
"I_GLACCOUNTTEXT",
"I_JOURNALENTRY",
"I_LEDGERCOMPANYCODECRCYROLES",
"I_MATERIAL",
"I_MATERIALDOCUMENTHEADER",
"I_MATERIALGROUP",
"I_MATERIALGROUPTEXT",
"I_MATERIALTEXT",
"I_PLANT",
"I_REFERENCEDOCUMENTTYPE",
"I_REFERENCEDOCUMENTTYPETEXT"
],
"ASSOCIATED":
[
"I_ACCOUNTINGDOCUMENTTYPE",
"I_CHARTOFACCOUNTS",
"I_COMPANYCODE",
"I_FISCALPERIODFORVARIANT",
"I_GLACCOUNTINCHARTOFACCOUNTS",
"I_JOURNALENTRY",
"I_MATERIAL",
"I_MATERIALDOCUMENTHEADER",
"I_MATERIALGROUP",
"I_PLANT",
"I_REFERENCEDOCUMENTTYPE"
],
"BASE":
[
"FAC_DART_Z3_MI_LINEITEM_BASE"
],
"ANNO_REF":
[],
"SCALAR_FUNCTION":
[],
"VERSION":0,
"ANNOREF_EVALUATION_ERROR":""
}
}*/
Learn More
- 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 Annotations — A Complete Guide
- 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