I_RO_SAFTProduct
RO SAFT Products
I_RO_SAFTProduct is a Composite CDS View that provides data about "RO SAFT Products" in SAP S/4HANA. It reads from 1 data source (I_MaterialPlant) and exposes 15 fields with key fields Product, Plant. It has 6 associations to related views.
Data Sources (1)
| Source | Alias | Join Type |
|---|---|---|
| I_MaterialPlant | _MaterialPlant | inner |
Parameters (2)
| Name | Type | Default |
|---|---|---|
| P_FromPostingDate | figen_rep_date_from | |
| P_ToPostingDate | figen_rep_date_to |
Associations (6)
| Cardinality | Target | Alias | Condition |
|---|---|---|---|
| [0..1] | I_RO_SAFTProductValuation | _Prodval | _Product.Product = _Prodval.Product and _MaterialPlant.Plant = _Prodval.ValuationArea and _Prodval.ValuationType is initial |
| [0..1] | I_RO_SAFTCommodityCode | _CommCode | _Product.Product = _CommCode.ProductID and _CommCode.RO_SAFTComCodeValidFromDate <= $parameters.P_ToPostingDate and _CommCode.RO_SAFTComCodeValidToDate >= $parameters.P_FromPostingDate |
| [0..1] | I_ProductText | _description | _Product.Product = _description.Product |
| [0..1] | I_RO_SAFTUnitOfMeasureMap | _Uom | _Product.BaseUnit = _Uom.SourceUnitOfMeasure |
| [0..1] | I_ProductUnitsOfMeasure | _ProductUom | _Product.Product = _ProductUom.Product and _Product.BaseUnit = _ProductUom.AlternativeUnit |
| [0..1] | I_RO_SAFTGoodsService | _GoodsService | _Product.ProductType = _GoodsService.MaterialType |
Annotations (12)
| Name | Value | Level | Field |
|---|---|---|---|
| AbapCatalog.sqlViewName | IROSAFTPRODUCT | view | |
| AbapCatalog.preserveKey | true | view | |
| VDM.viewType | #COMPOSITE | view | |
| AccessControl.authorizationCheck | #CHECK | view | |
| EndUserText.label | RO SAFT Products | view | |
| ObjectModel.representativeKey | Product | view | |
| AbapCatalog.compiler.compareFilter | true | view | |
| Analytics.internalName | #LOCAL | view | |
| ObjectModel.usageType.serviceQuality | #D | view | |
| ObjectModel.usageType.sizeCategory | #XL | view | |
| ObjectModel.usageType.dataClass | #TRANSACTIONAL | view | |
| ClientHandling.algorithm | #SESSION_VARIABLE | view |
Fields (15)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | Product | Product | ||
| KEY | Plant | I_MaterialPlant | Plant | |
| MaterialType | _Product | ProductType | ||
| RO_SAFTGoodsService | _GoodsService | RO_SAFTGoodsService | ||
| ProductGroup | _Product | ProductGroup | ||
| CommodityCodeText | _CommCode | CommodityCodeText | ||
| RO_SAFTComCodeValidFromDate | _CommCode | RO_SAFTComCodeValidFromDate | ||
| RO_SAFTComCodeValidToDate | _CommCode | RO_SAFTComCodeValidToDate | ||
| ProductName | _description | ProductName | ||
| ProductStandardID | _Product | ProductStandardID | ||
| BaseUnit | _Product | BaseUnit | ||
| SourceUnitOfMeasureFactor | _Uom | SourceUnitOfMeasureFactor | ||
| AlternativeUnit | _ProductUom | AlternativeUnit | ||
| QuantityNumerator | _ProductUom | QuantityNumerator | ||
| QuantityDenominator | _ProductUom | QuantityDenominator |
// active core entity
@AbapCatalog: {
sqlViewName: 'IROSAFTPRODUCT',
preserveKey: true
}
@VDM.viewType: #COMPOSITE
@AccessControl: {
authorizationCheck: #CHECK
}
@EndUserText.label: 'RO SAFT Products'
@ObjectModel.representativeKey: 'Product'
@AbapCatalog.compiler.compareFilter:true
@Analytics.internalName:#LOCAL
@ObjectModel.usageType.serviceQuality: #D
@ObjectModel.usageType.sizeCategory : #XL
@ObjectModel.usageType.dataClass: #TRANSACTIONAL
@ClientHandling.algorithm: #SESSION_VARIABLE
define view I_RO_SAFTProduct
with parameters
P_FromPostingDate : figen_rep_date_from,
P_ToPostingDate : figen_rep_date_to
as select distinct from I_Product as _Product
//association [0..1] to I_Material as _Material on $projection.Product = _Material.Material
inner join I_MaterialPlant as _MaterialPlant on _Product.Product = _MaterialPlant.Material
association [0..1] to I_RO_SAFTProductValuation as _Prodval on _Product.Product = _Prodval.Product
and _MaterialPlant.Plant = _Prodval.ValuationArea
and _Prodval.ValuationType is initial
association [0..1] to I_RO_SAFTCommodityCode as _CommCode on _Product.Product = _CommCode.ProductID
and _CommCode.RO_SAFTComCodeValidFromDate <= $parameters.P_ToPostingDate
and _CommCode.RO_SAFTComCodeValidToDate >= $parameters.P_FromPostingDate
//and _MaterialPlant.Plant = _CommCode.Plant
association [0..1] to I_ProductText as _description on _Product.Product = _description.Product
association [0..1] to I_RO_SAFTUnitOfMeasureMap as _Uom on _Product.BaseUnit = _Uom.SourceUnitOfMeasure
association [0..1] to I_ProductUnitsOfMeasure as _ProductUom on _Product.Product = _ProductUom.Product
and _Product.BaseUnit = _ProductUom.AlternativeUnit
//association [0..1] to I_RO_SAFTGoodsService as _GoodsService on _Product.MaterialType = _GoodsService.MaterialType
association [0..1] to I_RO_SAFTGoodsService as _GoodsService on _Product.ProductType = _GoodsService.MaterialType
{
key Product as Product,
key _MaterialPlant.Plant as Plant,
// cast( case when _Product.ProductType = 'DIEN'
// then 02
// else 01
// end as mtart ) as MaterialType,//GoodsServicesID,
_Product.ProductType as MaterialType,
_GoodsService.RO_SAFTGoodsService as RO_SAFTGoodsService,
// _Material.MaterialGroup as ProductGroup,
_Product.ProductGroup as ProductGroup,
_CommCode.CommodityCodeText as CommodityCodeText,
_CommCode.RO_SAFTComCodeValidFromDate as RO_SAFTComCodeValidFromDate,
_CommCode.RO_SAFTComCodeValidToDate as RO_SAFTComCodeValidToDate,
_description.ProductName as ProductName,
_Product.ProductStandardID as ProductStandardID,
case when ( _Prodval.IsLIFOAndFIFORelevant is not initial and _Prodval.LIFOValuationPoolNumber is initial )
then 'FIFO'
when ( _Prodval.IsLIFOAndFIFORelevant is not initial and _Prodval.LIFOValuationPoolNumber is not initial )
then 'LIFO'
when ( _Prodval.IsLIFOAndFIFORelevant is initial and _Prodval.InventoryValuationProcedure is not initial )
then _Prodval.InventoryValuationProcedure
end as ValuationClass, //ValuationMethod,
_Product.BaseUnit as BaseUnit,
_Uom.SourceUnitOfMeasureFactor as SourceUnitOfMeasureFactor,
_ProductUom.AlternativeUnit as AlternativeUnit,
_ProductUom.QuantityNumerator as QuantityNumerator,
_ProductUom.QuantityDenominator as QuantityDenominator,
//case when ( _Uom.SourceUnitOfMeasureFactor = _ProductUom.AlternativeUnit )
case when ( _Product.BaseUnit = _ProductUom.AlternativeUnit )
then 1
when ( _ProductUom.QuantityNumerator <> 0
and _ProductUom.QuantityDenominator <> 0 )
//then cast (_ProductUom.QuantityNumerator / _ProductUom.QuantityDenominator as int4)
//then div( _ProductUom.QuantityNumerator, _ProductUom.QuantityDenominator )
then division( _ProductUom.QuantityNumerator, _ProductUom.QuantityDenominator, 5 )
else 0
end /*as abap.fltp preserving type )*/ as ConversionFactor
}
where
_description.Language = $session.system_language /* '4' */
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"I_MATERIALPLANT",
"I_PRODUCT",
"I_PRODUCTTEXT",
"I_PRODUCTUNITSOFMEASURE",
"I_RO_SAFTCOMMODITYCODE",
"I_RO_SAFTGOODSSERVICE",
"I_RO_SAFTPRODUCTVALUATION",
"I_RO_SAFTUNITOFMEASUREMAP"
],
"ASSOCIATED":
[
"I_PRODUCTTEXT",
"I_PRODUCTUNITSOFMEASURE",
"I_RO_SAFTCOMMODITYCODE",
"I_RO_SAFTGOODSSERVICE",
"I_RO_SAFTPRODUCTVALUATION",
"I_RO_SAFTUNITOFMEASUREMAP"
],
"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