I_ProductsForSaleInRtlStore
Retail Store Products available for sale
I_ProductsForSaleInRtlStore is a Composite CDS View that provides data about "Retail Store Products available for sale" in SAP S/4HANA. It reads from 2 data sources (I_ProductPlant, I_Site) and exposes 3 fields with key fields Store, Product. It has 2 associations to related views. Part of development package ODATA_RETAIL_ST_COMMON.
Data Sources (2)
| Source | Alias | Join Type |
|---|---|---|
| I_ProductPlant | I_ProductPlant | from |
| I_Site | I_Site | inner |
Associations (2)
| Cardinality | Target | Alias | Condition |
|---|---|---|---|
| [0..1] | I_ProductSalesDeliveryPOS | _ProductPosControlSalesOrg | _ProductPosControlSalesOrg.Product = I_ProductPlant.Product and _ProductPosControlSalesOrg.ProductSalesOrg = I_Site.SalesOrganization and _ProductPosControlSalesOrg.ProductDistributionChnl = I_Site.DistributionChannel and _ProductPosControlSalesOrg.Plant = '' |
| [0..1] | I_ProductSalesDeliveryPOS | _ProductPosControlStore | _ProductPosControlStore.Product = I_ProductPlant.Product and _ProductPosControlStore.ProductSalesOrg = I_Site.SalesOrganization and _ProductPosControlStore.ProductDistributionChnl = I_Site.DistributionChannel and _ProductPosControlStore.Plant = I_Site.Site |
Annotations (11)
| Name | Value | Level | Field |
|---|---|---|---|
| ClientHandling.algorithm | #SESSION_VARIABLE | view | |
| ObjectModel.usageType.dataClass | #MIXED | view | |
| ObjectModel.usageType.serviceQuality | #C | view | |
| ObjectModel.usageType.sizeCategory | #XL | view | |
| AbapCatalog.sqlViewName | IRTSTSELLABLPROD | view | |
| AbapCatalog.compiler.compareFilter | true | view | |
| AbapCatalog.preserveKey | true | view | |
| AccessControl.authorizationCheck | #CHECK | view | |
| AccessControl.personalData.blocking | #NOT_REQUIRED | view | |
| VDM.viewType | #COMPOSITE | view | |
| EndUserText.label | Retail Store Products available for sale | view |
Fields (3)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | Store | I_ProductPlant | Plant | |
| KEY | Product | I_ProductPlant | Product | |
| _Plant | _Plant |
@ClientHandling.algorithm: #SESSION_VARIABLE
@ObjectModel.usageType.dataClass: #MIXED
@ObjectModel.usageType.serviceQuality: #C
@ObjectModel.usageType.sizeCategory: #XL
@AbapCatalog.sqlViewName: 'IRTSTSELLABLPROD'
@AbapCatalog.compiler.compareFilter: true
@AbapCatalog.preserveKey: true
@AccessControl.authorizationCheck: #CHECK
@AccessControl.personalData.blocking: #NOT_REQUIRED
@VDM.viewType: #COMPOSITE
@EndUserText.label: 'Retail Store Products available for sale'
define view I_ProductsForSaleInRtlStore
as select from I_ProductPlant
inner join I_Site on I_ProductPlant.Plant = I_Site.Site
association [0..1] to I_ProductSalesDeliveryPOS as _ProductPosControlSalesOrg on _ProductPosControlSalesOrg.Product = I_ProductPlant.Product
and _ProductPosControlSalesOrg.ProductSalesOrg = I_Site.SalesOrganization
and _ProductPosControlSalesOrg.ProductDistributionChnl = I_Site.DistributionChannel
and _ProductPosControlSalesOrg.Plant = ''
association [0..1] to I_ProductSalesDeliveryPOS as _ProductPosControlStore on _ProductPosControlStore.Product = I_ProductPlant.Product
and _ProductPosControlStore.ProductSalesOrg = I_Site.SalesOrganization
and _ProductPosControlStore.ProductDistributionChnl = I_Site.DistributionChannel
and _ProductPosControlStore.Plant = I_Site.Site
{
key I_ProductPlant.Plant as Store,
key I_ProductPlant.Product,
_Plant
}
// Select only stores
where
I_Site.SiteCategory = 'A'
and(
(
// Allow entry when PosControl for Store exists.
_ProductPosControlStore.Product is not null
and(
_ProductPosControlStore.StoreSaleStartDate <= $session.system_date
and _ProductPosControlStore.StoreSaleEndDate >= $session.system_date
)
)
or(
// If ProductPosControlStore does not exist, then use the sales org specific ruleset
_ProductPosControlSalesOrg.Product is not null
and _ProductPosControlStore.Product is null
and(
_ProductPosControlSalesOrg.StoreSaleStartDate <= $session.system_date
and _ProductPosControlSalesOrg.StoreSaleEndDate >= $session.system_date
)
)
)
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