P_MaterialValuationPrices

DDL: P_MATERIALVALUATIONPRICES SQL: PMATVALPRICES Type: view COMPOSITE

P_MaterialValuationPrices is a Composite CDS View in SAP S/4HANA. It reads from 5 data sources (P_MlPrice_Period_By_Periodtype, R_MaterialLedgerPriceCmptblty, P_MlPrice_By_Periodtype, R_MatlPriceDataMigrationStatus, R_MatlPriceDataMigrationStatus) and exposes 81 fields with key fields CostEstimate, Ledger, CurrencyRole, FiscalYear, FiscalPeriod. It has 1 association to related views.

Data Sources (5)

Associations (1)

CardinalityTargetAliasCondition
[0..1] R_MatlLedgerValnCrcyRole _MLCurrencyInfo _MLCurrencyInfo.LedgerValuationCurrencyRole = mlper.CurrencyRole and _MLCurrencyInfo.CompanyCode = mlper.CompanyCode

Annotations (6)

NameValueLevelField
AbapCatalog.sqlViewName PMATVALPRICES view
AbapCatalog.compiler.compareFilter true view
AccessControl.authorizationCheck #NOT_REQUIRED view
ClientHandling.algorithm #SESSION_VARIABLE view
VDM.private true view
VDM.viewType #COMPOSITE view

Fields (81)

KeyFieldSource TableSource FieldDescription
KEY CostEstimate P_MlPrice_Period_By_Periodtype CostEstimate Cost EstimateNo
KEY Ledger Ledger
KEY CurrencyRole P_MlPrice_Period_By_Periodtype CurrencyRole Curr./Val. Type
KEY FiscalYear P_MlPrice_Period_By_Periodtype FiscalYear G/L Fiscal Year
KEY FiscalPeriod P_MlPrice_Period_By_Periodtype FiscalPeriod Tax period
KEY PeriodType PeriodType PeriodIndicator
KEY FiscalPeriodType FiscalPeriodType
Material P_MlPrice_Period_By_Periodtype Material Vehicle Model
ValuationArea P_MlPrice_Period_By_Periodtype ValuationArea Valuation Area
InventoryValuationType R_MaterialLedgerPriceCmptblty InventoryValuationType Valuation Type
SalesOrder SalesOrder SD Document
SalesOrderItem SalesOrderItem Sales Order Item
Supplier Supplier Supplier
WBSElementInternalID WBSElementInternalID WBS Internal ID
WBSElementExternalID WBSElementExternalID WBS Element External ID
InvtryValnSpecialStockType InvtryValnSpecialStockType Special Stock
InventorySpecialStockValnType InventorySpecialStockValnType Valuation
IsSupplierStockValuation IsSupplierStockValuation Vendor stk val.
CompanyCode CompanyCode Receiver Company Code
PriceDeterminationControl PriceDeterminationControl Price Determ.
MaterialPriceControl MaterialPriceControl Price Control
MaterialPriceUnitQty MaterialPriceUnitQty Price unit
Currency Currency Valuation Crcy
MovingAveragePrice MovingAveragePrice Per. Unit Price
StandardPrice StandardPrice Standard price
InventoryPrice InventoryPrice Price
FuturePrice FuturePrice Inventory Price
FuturePriceValidityStartDate FuturePriceValidityStartDate Valid from
PlannedPrice PlannedPrice Inventory Price
FutrCostEstValuationVariant FutrCostEstValuationVariant
FutureCostEstFiscalYear FutureCostEstFiscalYear
FutureCostEstimateFiscalPeriod FutureCostEstimateFiscalPeriod
FutureCostEstCostingVersion FutureCostEstCostingVersion
FixedPortionOfPlannedPrice FixedPortionOfPlannedPrice
LedgerName _MLCurrencyInfo LedgerName Ledger Name
CurrencyRoleName _MLCurrencyInfo CurrencyRoleName
LegalCurrencyRole _MLCurrencyInfo LegalCurrencyRole
LegalCurrencyRoleName _MLCurrencyInfo LegalCurrencyRoleName
AccountingValuationView _MLCurrencyInfo AccountingValuationView
AcctgValnVwSubviewCombinedName _MLCurrencyInfo AcctgValnVwSubviewCombinedName
CompanyCodekeyCostEstimate
KEY Ledger Ledger Ledger
KEY CurrencyRole CurrencyRole Curr./Val. Type
KEY FiscalYear FiscalYear G/L Fiscal Year
KEY FiscalPeriod FiscalPeriod Tax period
KEY PeriodType PeriodType PeriodIndicator
KEY FiscalPeriodType FiscalPeriodType
Material Material Vehicle Model
ValuationArea ValuationArea Valuation Area
InventoryValuationType InventoryValuationType Valuation Type
SalesOrder SalesOrder SD Document
SalesOrderItem SalesOrderItem Sales Order Item
Supplier Supplier Supplier
WBSElementInternalID WBSElementInternalID WBS Internal ID
WBSElementExternalID WBSElementExternalID WBS Element External ID
InvtryValnSpecialStockType InvtryValnSpecialStockType Special Stock
InventorySpecialStockValnType InventorySpecialStockValnType Valuation
IsSupplierStockValuation IsSupplierStockValuation Vendor stk val.
CompanyCode CompanyCode Receiver Company Code
PriceDeterminationControl PriceDeterminationControl Price Determ.
MaterialPriceControl MaterialPriceControl Price Control
MaterialPriceUnitQty MaterialPriceUnitQty Price unit
Currency Currency Valuation Crcy
MovingAveragePrice MovingAveragePrice Per. Unit Price
StandardPrice StandardPrice Standard price
InventoryPrice InventoryPrice Price
FuturePrice FuturePrice Inventory Price
FuturePriceValidityStartDate FuturePriceValidityStartDate Valid from
PlannedPrice PlannedPrice Inventory Price
FutrCostEstValuationVariant FutrCostEstValuationVariant
FutureCostEstFiscalYear FutureCostEstFiscalYear
FutureCostEstimateFiscalPeriod FutureCostEstimateFiscalPeriod
FutureCostEstCostingVersion FutureCostEstCostingVersion
FixedPortionOfPlannedPrice FixedPortionOfPlannedPrice
LedgerName _MLCurrencyInfo LedgerName Ledger Name
CurrencyRoleName _MLCurrencyInfo CurrencyRoleName
LegalCurrencyRole _MLCurrencyInfo LegalCurrencyRole
LegalCurrencyRoleName _MLCurrencyInfo LegalCurrencyRoleName
AccountingValuationView _MLCurrencyInfo AccountingValuationView
AcctgValnVwSubviewCombinedName _MLCurrencyInfo AcctgValnVwSubviewCombinedName
LedgerValnCrcyRoleIsUsedInLogs _MLCurrencyInfo LedgerValnCrcyRoleIsUsedInLogs Is Log. Curr. Type

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 P_MaterialValuationPrices.
-- 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: PMATVALPRICES

CREATE VIEW P_MaterialValuationPrices AS
SELECT
  mlper.CostEstimate AS CostEstimate,
  coalesce(_MLCurrencyInfo.Ledger, cast(' ' as fins_ledger)) AS Ledger,
  mlper.CurrencyRole AS CurrencyRole,
  mlper.FiscalYear AS FiscalYear,
  mlper.FiscalPeriod AS FiscalPeriod,
  PeriodType,
  FiscalPeriodType,
  mlper.Material AS Material,
  mlper.ValuationArea AS ValuationArea,
  mlprc.InventoryValuationType AS InventoryValuationType,
  SalesOrder,
  SalesOrderItem,
  Supplier,
  WBSElementInternalID,
  WBSElementExternalID,
  InvtryValnSpecialStockType,
  InventorySpecialStockValnType,
  IsSupplierStockValuation,
  CompanyCode,
  PriceDeterminationControl,
  MaterialPriceControl,
  MaterialPriceUnitQty,
  Currency,
  MovingAveragePrice,
  StandardPrice,
  InventoryPrice,
  FuturePrice,
  FuturePriceValidityStartDate,
  PlannedPrice,
  FutrCostEstValuationVariant,
  FutureCostEstFiscalYear,
  FutureCostEstimateFiscalPeriod,
  FutureCostEstCostingVersion,
  FixedPortionOfPlannedPrice,
  _MLCurrencyInfo.LedgerName AS LedgerName,
  _MLCurrencyInfo.CurrencyRoleName AS CurrencyRoleName,
  _MLCurrencyInfo.LegalCurrencyRole AS LegalCurrencyRole,
  _MLCurrencyInfo.LegalCurrencyRoleName AS LegalCurrencyRoleName,
  _MLCurrencyInfo.AccountingValuationView AS AccountingValuationView,
  _MLCurrencyInfo.AcctgValnVwSubviewCombinedName AS AcctgValnVwSubviewCombinedName,
  _MLCurrencyInfo.LedgerValnCrcyRoleIsUsedInLogs as LedgerValnCrcyRoleIsUsedInLogs AS CompanyCodekeyCostEstimate,
  _MLCurrencyInfo.LedgerValnCrcyRoleIsUsedInLogs AS LedgerValnCrcyRoleIsUsedInLogs
FROM P_MlPrice_Period_By_Periodtype AS mlper
INNER JOIN R_MatlPriceDataMigrationStatus AS tf ON /* join condition not captured in parsed metadata */
INNER JOIN R_MaterialLedgerPriceCmptblty AS mlprc ON /* join condition not captured in parsed metadata */
LEFT OUTER JOIN R_MatlLedgerValnCrcyRole AS _MLCurrencyInfo ON _MLCurrencyInfo.LedgerValuationCurrencyRole = mlper.CurrencyRole AND _MLCurrencyInfo.CompanyCode = mlper.CompanyCode  -- association [0..1]
-- UNION ALL with additional select branch(es): P_MlPrice_By_Periodtype
;