R_MatlPriceSpclStockValnStrgy
Mat Price Spec Stock Valuation Strategy
R_MatlPriceSpclStockValnStrgy is a Composite CDS View that provides data about "Mat Price Spec Stock Valuation Strategy" in SAP S/4HANA. It reads from 9 data sources and exposes 25 fields with key fields CostEstimate, CurrencyRole, Ledger, CurrencyRole, Ledger.
Data Sources (9)
| Source | Alias | Join Type |
|---|---|---|
| I_MatlLedgerValnCrcyRoleName | curtp | inner |
| I_MaterialLedgerPrice | fmltp | union_all |
| ckmlhd | hd | inner |
| t001w | p | inner |
| t001w | plant | inner |
| ckmlpr | pr | from |
| t001k | t | inner |
| R_MatlPriceDataMigrationStatus | tf | inner |
| R_MatlPriceDataMigrationStatus | tf | inner |
Annotations (11)
| Name | Value | Level | Field |
|---|---|---|---|
| AbapCatalog.sqlViewName | RMPSSVSTRGY | view | |
| AbapCatalog.compiler.compareFilter | true | view | |
| AbapCatalog.preserveKey | true | view | |
| VDM.viewType | #COMPOSITE | view | |
| AccessControl.authorizationCheck | #NOT_REQUIRED | view | |
| EndUserText.label | Mat Price Spec Stock Valuation Strategy | view | |
| ClientHandling.algorithm | #SESSION_VARIABLE | view | |
| VDM.lifecycle.contract.type | #SAP_INTERNAL_API | view | |
| ObjectModel.usageType.sizeCategory | #XL | view | |
| ObjectModel.usageType.serviceQuality | #C | view | |
| ObjectModel.usageType.dataClass | #MIXED | view |
Fields (25)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | CostEstimate | ckmlpr | kalnr | |
| KEY | CurrencyRole | I_MatlLedgerValnCrcyRoleName | CurrencyRole | |
| KEY | Ledger | I_MatlLedgerValnCrcyRoleName | Ledger | |
| MatlPrcValdtyEndFsclYearPeriod | ||||
| Material | ckmlhd | matnr | ||
| ValuationArea | ckmlhd | bwkey | ||
| ValuationType | ckmlhd | bwtar | ||
| Plant | t001w | werks | ||
| SalesOrder | ckmlhd | vbeln | ||
| SalesOrderItem | ckmlhd | posnr | ||
| WBSElementInternalID | ||||
| MaterialPriceType | ||||
| CostEstimateasCostEstimate | ||||
| KEY | CurrencyRole | I_MaterialLedgerPrice | CurrencyRole | |
| KEY | Ledger | I_MaterialLedgerPrice | Ledger | |
| MatlPrcValdtyEndFsclYearPeriod | I_MaterialLedgerPrice | MatlPrcValdtyEndFsclYearPeriod | ||
| Material | I_MaterialLedgerPrice | Material | ||
| ValuationArea | I_MaterialLedgerPrice | ValuationArea | ||
| ValuationType | I_MaterialLedgerPrice | InventoryValuationType | ||
| Plant | t001w | werks | ||
| SalesOrder | I_MaterialLedgerPrice | SalesOrder | ||
| SalesOrderItem | I_MaterialLedgerPrice | SalesOrderItem | ||
| WBSElementInternalID | ||||
| MaterialPriceType | I_MaterialLedgerPrice | MaterialPriceType | ||
| CurPlanProjSlsOrdValnStrategy | I_MaterialLedgerPrice | CurPlanProjSlsOrdValnStrategy |
@AbapCatalog.sqlViewName: 'RMPSSVSTRGY'
@AbapCatalog.compiler.compareFilter: true
@AbapCatalog.preserveKey: true
@VDM.viewType: #COMPOSITE
@AccessControl.authorizationCheck: #NOT_REQUIRED
@EndUserText.label: 'Mat Price Spec Stock Valuation Strategy'
@ClientHandling.algorithm: #SESSION_VARIABLE
@VDM.lifecycle.contract.type: #SAP_INTERNAL_API
@ObjectModel.usageType.sizeCategory: #XL
@ObjectModel.usageType.serviceQuality: #C
@ObjectModel.usageType.dataClass: #MIXED
define view R_MatlPriceSpclStockValnStrgy
as select from ckmlpr as pr
inner join R_MatlPriceDataMigrationStatus as tf on(
tf.MatlPriceDataMigrationStatus = 'X'
)
or(
tf.MatlPriceDataMigrationStatus = 'R'
)
inner join ckmlhd as hd on hd.kalnr = pr.kalnr
and hd.sobkz <> ''
inner join t001k as t on t.bwkey = hd.bwkey
inner join t001w as p on p.bwkey = hd.bwkey
inner join I_MatlLedgerValnCrcyRoleName as curtp on curtp.CompanyCode = t.bukrs
and curtp.LedgerValuationCurrencyRole = pr.curtp
{
key pr.kalnr as CostEstimate,
key curtp.CurrencyRole as CurrencyRole,
key curtp.Ledger as Ledger,
cast( '9999012' as fml_yearper_nconv ) as MatlPrcValdtyEndFsclYearPeriod,
hd.matnr as Material,
hd.bwkey as ValuationArea,
hd.bwtar as ValuationType,
p.werks as Plant,
hd.vbeln as SalesOrder,
hd.posnr as SalesOrderItem,
cast ( hd.pspnr as ps_psp_pnr_core ) as WBSElementInternalID,
cast( 'INVPR' as fml_price_type ) as MaterialPriceType,
pr.lbwst as CurPlanProjSlsOrdValnStrategy
}
where
pr.sdm_version is initial
union all select from I_MaterialLedgerPrice as fmltp
inner join R_MatlPriceDataMigrationStatus as tf on(
tf.MatlPriceDataMigrationStatus = 'F'
)
or(
tf.MatlPriceDataMigrationStatus = 'R'
)
left outer to one join ckmlhd as hd on hd.kalnr = fmltp.CostEstimate
inner join t001w as plant on plant.bwkey = fmltp.ValuationArea
{
key fmltp.CostEstimate as CostEstimate,
key fmltp.CurrencyRole as CurrencyRole,
key fmltp.Ledger as Ledger,
fmltp.MatlPrcValdtyEndFsclYearPeriod as MatlPrcValdtyEndFsclYearPeriod,
fmltp.Material as Material,
fmltp.ValuationArea as ValuationArea,
fmltp.InventoryValuationType as ValuationType,
plant.werks as Plant,
fmltp.SalesOrder as SalesOrder,
fmltp.SalesOrderItem as SalesOrderItem,
cast ( fmltp.WBSElementInternalID as ps_psp_pnr_core ) as WBSElementInternalID,
fmltp.MaterialPriceType as MaterialPriceType,
fmltp.CurPlanProjSlsOrdValnStrategy as CurPlanProjSlsOrdValnStrategy
}
where
(
(
fmltp.MaterialPriceType = 'INVPR'
and fmltp.MaterialPriceControl = 'S'
)
or(
fmltp.MaterialPriceType = 'STDPR'
)
)
and fmltp.MatlPrcValidityEndFiscalYear = '9999'
and fmltp.StkMaterialPriceValuationType <> 'M'
and(
(
hd.price_sdm_yearper <> '0000000'
and hd.price_sdm_yearper <= fmltp.MatlPrcValdtyStrtFsclYearPerd
)
or(
tf.MatlPriceDataMigrationStatus = 'F'
)
)
// and fmltp.CurPlanProjSlsOrdValnStrategy <> ' ')
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"I_MATERIALLEDGERPRICE",
"I_MATLLEDGERVALNCRCYROLENAME",
"R_MATLPRICEDATAMIGRATIONSTATUS",
"CKMLHD",
"CKMLPR",
"T001K",
"T001W"
],
"ASSOCIATED":
[],
"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