C_CmpstnHistory

DDL: C_CMPSTNHISTORY Type: view CONSUMPTION

History of Composition

C_CmpstnHistory is a Consumption CDS View that provides data about "History of Composition" in SAP S/4HANA. It reads from 1 data source (I_ChmlComposition) and exposes 19 fields with key field ChmlCompositionUUID. It has 3 associations to related views.

Data Sources (1)

SourceAliasJoin Type
I_ChmlComposition ChmlComposition from

Associations (3)

CardinalityTargetAliasCondition
[1..1] I_ChmlCompositionStatusText _CompositionStatusText ChmlComposition.ChmlCompositionStatus = _CompositionStatusText.ChmlCompositionStatus and _CompositionStatusText.Language = $session.system_language
[1..1] I_BusinessUserBasic _LastChangedByUser ChmlComposition.LastChangedByUser = _LastChangedByUser.UserID
[0..1] I_BusinessUserBasic _ReleasedByUser ChmlComposition.ReleasedByUser = _ReleasedByUser.BusinessPartner

Annotations (11)

NameValueLevelField
AbapCatalog.sqlViewName CMPSTNHISTORY view
AbapCatalog.compiler.compareFilter true view
AbapCatalog.preserveKey true view
AccessControl.authorizationCheck #CHECK view
AccessControl.personalData.blocking #NOT_REQUIRED view
ClientHandling.algorithm #SESSION_VARIABLE view
VDM.viewType #CONSUMPTION view
ObjectModel.usageType.dataClass #MIXED view
ObjectModel.usageType.sizeCategory #L view
ObjectModel.usageType.serviceQuality #C view
EndUserText.label History of Composition view

Fields (19)

KeyFieldSource TableSource FieldDescription
KEY ChmlCompositionUUID I_ChmlComposition ChmlCompositionUUID Chemical Composition
ChmlCmplncInfoUUID I_ChmlComposition ChmlCmplncInfoUUID Chemical Compliance Information PP
SubstanceUUID I_ChmlComposition SubstanceUUID Substance
ChmlCompositionType I_ChmlComposition ChmlCompositionType Legal Area
ProdCmplncLegalArea I_ChmlComposition ProdCmplncLegalArea Legal Area
PolymerCompositionIntID I_ChmlComposition PolymerCompositionIntID Internal Number
ChmlCompositionStatus I_ChmlComposition ChmlCompositionStatus Processing Status
ChmlCompositionStatusName _CompositionStatusText ChmlCompositionStatusName
LastChangedByUserFullName _LastChangedByUser PersonFullName Full Name
LastChangeDateTime I_ChmlComposition LastChangeUTCDateTime Time Stamp
ReleasedByUserName _ReleasedByUser PersonFullName Full Name
ReleaseDateTime I_ChmlComposition ReleaseDateTime Composition Released On
ValidityStartDateTime I_ChmlComposition ValidityStartDateTime Valid From Timestamp
ValidityEndDateTime I_ChmlComposition ValidityEndDateTime Valid To Timestamp
CreationUTCDateTime I_ChmlComposition CreationUTCDateTime Time Stamp
_ChmlCmplncInfo _ChmlCmplncInfo
_Substance _Substance
_CompositionType _CompositionType
_CompositionStatus _CompositionStatus

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 C_CmpstnHistory.
-- 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.

CREATE VIEW C_CmpstnHistory AS
SELECT
  ChmlComposition.ChmlCompositionUUID AS ChmlCompositionUUID,
  ChmlComposition.ChmlCmplncInfoUUID AS ChmlCmplncInfoUUID,
  ChmlComposition.SubstanceUUID AS SubstanceUUID,
  ChmlComposition.ChmlCompositionType AS ChmlCompositionType,
  ChmlComposition.ProdCmplncLegalArea AS ProdCmplncLegalArea,
  ChmlComposition.PolymerCompositionIntID AS PolymerCompositionIntID,
  ChmlComposition.ChmlCompositionStatus AS ChmlCompositionStatus,
  _CompositionStatusText.ChmlCompositionStatusName AS ChmlCompositionStatusName,
  _LastChangedByUser.PersonFullName AS LastChangedByUserFullName,
  ChmlComposition.LastChangeUTCDateTime AS LastChangeDateTime,
  _ReleasedByUser.PersonFullName AS ReleasedByUserName,
  ChmlComposition.ReleaseDateTime AS ReleaseDateTime,
  ChmlComposition.ValidityStartDateTime AS ValidityStartDateTime,
  ChmlComposition.ValidityEndDateTime AS ValidityEndDateTime,
  ChmlComposition.CreationUTCDateTime AS CreationUTCDateTime
FROM I_ChmlComposition AS ChmlComposition
LEFT OUTER JOIN I_ChmlCompositionStatusText AS _CompositionStatusText ON ChmlComposition.ChmlCompositionStatus = _CompositionStatusText.ChmlCompositionStatus AND _CompositionStatusText.Language = $session.system_language  -- association [1..1]
LEFT OUTER JOIN I_BusinessUserBasic AS _LastChangedByUser ON ChmlComposition.LastChangedByUser = _LastChangedByUser.UserID  -- association [1..1]
LEFT OUTER JOIN I_BusinessUserBasic AS _ReleasedByUser ON ChmlComposition.ReleasedByUser = _ReleasedByUser.BusinessPartner  -- association [0..1]
;