P_SECURITYPRICEDATE
P_SECURITYPRICEDATE is a Composite CDS View in SAP S/4HANA. It reads from 2 data sources (I_CalendarDate, I_SECURITYPRICE) and exposes 5 fields with key fields SecurityClass, SecurityExchange, SecurityClassPriceType, KeyDate.
Data Sources (2)
| Source | Alias | Join Type |
|---|---|---|
| I_CalendarDate | _CalendarDate | from |
| I_SECURITYPRICE | SECURITYPRICE | left_outer |
Parameters (1)
| Name | Type | Default |
|---|---|---|
| P_KeyDate | vdm_v_key_date |
Annotations (7)
| Name | Value | Level | Field |
|---|---|---|---|
| AbapCatalog.sqlViewName | PSECPRICEDATE | view | |
| ClientHandling.algorithm | #SESSION_VARIABLE | view | |
| AbapCatalog.compiler.compareFilter | true | view | |
| AccessControl.authorizationCheck | #NOT_REQUIRED | view | |
| VDM.viewType | #COMPOSITE | view | |
| ObjectModel.usageType.serviceQuality | #B | view | |
| VDM.private | true | view |
Fields (5)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | SecurityClass | I_SECURITYPRICE | SecurityClass | |
| KEY | SecurityExchange | I_SECURITYPRICE | SecurityExchange | |
| KEY | SecurityClassPriceType | I_SECURITYPRICE | SecurityClassPriceType | |
| KEY | KeyDate | I_CalendarDate | CalendarDate | |
| TreasuryPriceDate |
@AbapCatalog.sqlViewName: 'PSECPRICEDATE'
@ClientHandling.algorithm: #SESSION_VARIABLE
@AbapCatalog.compiler.compareFilter: true
@AccessControl.authorizationCheck: #NOT_REQUIRED
@VDM.viewType: #COMPOSITE
@ObjectModel.usageType.serviceQuality: #B
@VDM.private:true
define view P_SECURITYPRICEDATE
with parameters
@Environment.systemField: #SYSTEM_DATE
P_KeyDate : vdm_v_key_date
as select from I_CalendarDate as _CalendarDate
left outer join I_SECURITYPRICE as SECURITYPRICE on _CalendarDate.CalendarDate >= SECURITYPRICE.TreasuryPriceDate
{
key SECURITYPRICE.SecurityClass,
key SECURITYPRICE.SecurityExchange,
key SECURITYPRICE.SecurityClassPriceType,
key _CalendarDate.CalendarDate as KeyDate,
max(SECURITYPRICE.TreasuryPriceDate) as TreasuryPriceDate
}
where
_CalendarDate.CalendarDate <= $parameters.P_KeyDate
and _CalendarDate.CalendarDate >= SECURITYPRICE.TreasuryPriceDate
group by
SECURITYPRICE.SecurityClass,
SECURITYPRICE.SecurityExchange,
SECURITYPRICE.SecurityClassPriceType,
_CalendarDate.CalendarDate
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"I_CALENDARDATE",
"I_SECURITYPRICE"
],
"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