P_PrevCalendarDateYearMonth

DDL: P_PREVCALENDARDATEYEARMONTH Type: view_entity COMPOSITE Package: VDM_SD_ANALYTICS

Year Month of Previous Calendar Date in F2601

P_PrevCalendarDateYearMonth is a Composite CDS View that provides data about "Year Month of Previous Calendar Date in F2601" in SAP S/4HANA. It reads from 1 data source (I_CalendarDate) and exposes 5 fields with key field CalendarDate. Part of development package VDM_SD_ANALYTICS.

Data Sources (1)

SourceAliasJoin Type
I_CalendarDate I_CalendarDate from

Parameters (2)

NameTypeDefault
P_Date sydatum
P_NumberOfMonths num_of_months

Annotations (7)

NameValueLevelField
Metadata.ignorePropagatedAnnotations true view
ObjectModel.usageType.dataClass #MIXED view
ObjectModel.usageType.serviceQuality #C view
ObjectModel.usageType.sizeCategory #S view
VDM.private true view
VDM.viewType #COMPOSITE view
AccessControl.authorizationCheck #NOT_REQUIRED view

Fields (5)

KeyFieldSource TableSource FieldDescription
KEY CalendarDate CalendarDate Calendar Date
CalendarMonth CalendarMonth Calendar Month
_CalendarMonth _CalendarMonth
YearMonth
IsCurrentYearTransaction

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_PrevCalendarDateYearMonth.
-- 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.
-- Parameters: P_Date : sydatum, P_NumberOfMonths : num_of_months

CREATE VIEW P_PrevCalendarDateYearMonth AS
SELECT
  CalendarDate,
  CalendarMonth,
  left(dats_add_months(CalendarDate, 12,'FAIL'), 6) AS YearMonth,
  ' ' AS IsCurrentYearTransaction
FROM I_CalendarDate
;