Deprecated
This CDS view is deprecated in S/4HANA. Use C_ProductCostByOrderQuery instead. View all deprecated CDS views →

C_COProductCostByOrder1

DDL: C_COPRODUCTCOSTBYORDER1 SQL: CFIPRDTCOSTBYOR1 Type: view CONSUMPTION Package: ODATA_PRODUCTION_COST_ANALYSIS

CO Product Cost By Order

C_COProductCostByOrder1 is a Consumption CDS View that provides data about "CO Product Cost By Order" in SAP S/4HANA. It reads from 1 data source (I_COProductCostByOrder) and exposes 41 fields with key field OrderID. It has 1 association to related views. Part of development package ODATA_PRODUCTION_COST_ANALYSIS.

Data Sources (1)

SourceAliasJoin Type
I_COProductCostByOrder I_COProductCostByOrder from

Parameters (6)

NameTypeDefault
P_FromFiscalYearPeriod fins_fyearperiod
P_ToFiscalYearPeriod fins_fyearperiod
P_PlanningCategory fcom_category
P_ResultAnalysisVersion versn_abgr
P_Language sylangu
P_CurrencyRole fac_crcyrole

Associations (1)

CardinalityTargetAliasCondition
[0..*] I_MaterialText _MaterialText $projection.Material = _MaterialText.Material

Annotations (20)

NameValueLevelField
AbapCatalog.sqlViewName CFIPRDTCOSTBYOR1 view
ClientHandling.type #CLIENT_DEPENDENT view
ClientHandling.algorithm #SESSION_VARIABLE view
VDM.viewType #CONSUMPTION view
AbapCatalog.compiler.compareFilter true view
AccessControl.authorizationCheck #CHECK view
VDM.lifecycle.status #DEPRECATED view
VDM.lifecycle.successor C_ProductCostByOrderQuery view
EndUserText.label CO Product Cost By Order view
Search.searchable true view
ObjectModel.usageType.serviceQuality #D view
ObjectModel.usageType.sizeCategory #XXL view
ObjectModel.usageType.dataClass #MIXED view
Metadata.ignorePropagatedAnnotations true view
Metadata.allowExtensions true view
AccessControl.personalData.blocking #BLOCKED_DATA_EXCLUDED view
UI.headerInfo.typeName Order view
UI.headerInfo.typeNamePlural Orders view
UI.headerInfo.title.value OrderID view
UI.headerInfo.description.value MaterialName view

Fields (41)

KeyFieldSource TableSource FieldDescription
KEY OrderID OrderID Order ID
ObjectInternalID ObjectInternalID Object number
OrderType OrderType Order Type
OrderCategory OrderCategory Order Category
ExternalOrder ExternalOrder Ext. order no.
OrderDescription OrderDescription
Plant Plant Valuation Area
ProductionUnit Unit of Measure
ControllingArea ControllingArea Controlling Area
CompanyCode CompanyCode Receiver Company Code
BusinessArea BusinessArea Business Area
ProfitCenter ProfitCenter Profit Center
ResponsibleCostCenter ResponsibleCostCenter Responsible Cost Center
MfgOrderHasMultipleItems MfgOrderHasMultipleItems
ActualCostsCostingVariant ActualCostsCostingVariant Act. Costing Variant
CreatedByUser CreatedByUser User Name
CreationDate CreationDate Time Stamp
LastChangedByUser LastChangedByUser User Name
LastChangeDate LastChangeDate Time Stamp
TechnicalCompletionDate TechnicalCompletionDate
Material Material Vehicle Model
MRPPlant Plant
StorageLocation StorageLocation
ProductionVersion ProductionVersion Version ID
ScheduledBasicEndDate ScheduledBasicEndDate Sched. finish
ScheduledReleaseDate ScheduledReleaseDate
ActualStartDate ActualStartDate Actual Start
ConfirmedEndDate ConfirmedEndDate
ActualReleasedDate ActualReleasedDate
ControllingObjectStatus ControllingObjectStatus Status
SalesOrder SalesOrder SD Document
PlanOutputQuantity PlanOutputQuantity
ActualOutputQuantity ActualOutputQuantity
ActlPlanDiffOutputQuantity
ActlPlanDiffOutpQtyPercent ActlPlanDiffOutpQtyPercent
MaterialName
_CompanyCode _CompanyCode
_Material _Material
_CreatedByContactCard _CreatedByContactCard
_LastChangedByUserContactCard _LastChangedByUserContactCard
_MaterialText _MaterialText

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_COProductCostByOrder1.
-- 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.
-- SQL view name: CFIPRDTCOSTBYOR1
-- Parameters: P_FromFiscalYearPeriod : fins_fyearperiod, P_ToFiscalYearPeriod : fins_fyearperiod, P_PlanningCategory : fcom_category, P_ResultAnalysisVersion : versn_abgr, P_Language : sylangu, P_CurrencyRole : fac_crcyrole

CREATE VIEW C_COProductCostByOrder1 AS
SELECT
  OrderID,
  ObjectInternalID,
  OrderType,
  OrderCategory,
  ExternalOrder,
  OrderDescription,
  Plant,
  cast(BaseUnit as fis_meinh) AS ProductionUnit,
  ControllingArea,
  CompanyCode,
  BusinessArea,
  ProfitCenter,
  ResponsibleCostCenter,
  MfgOrderHasMultipleItems,
  ActualCostsCostingVariant,
  CreatedByUser,
  CreationDate,
  LastChangedByUser,
  LastChangeDate,
  TechnicalCompletionDate,
  Material,
  cast(MRPPlant as fis_co_pwerk) AS MRPPlant,
  cast(StorageLocation as fis_lgort_d) AS StorageLocation,
  ProductionVersion,
  ScheduledBasicEndDate,
  ScheduledReleaseDate,
  ActualStartDate,
  ConfirmedEndDate,
  ActualReleasedDate,
  ControllingObjectStatus,
  SalesOrder,
  PlanOutputQuantity,
  ActualOutputQuantity,
  cast(ActlPlanDiffOutputQuantity as fis_actlplandiffoutputquantity) AS ActlPlanDiffOutputQuantity,
  ActlPlanDiffOutpQtyPercent,
  cast(_Material._Text[1: Language = $parameters.P_Language].MaterialName as fis_material_text) AS MaterialName
FROM I_COProductCostByOrder
LEFT OUTER JOIN I_MaterialText AS _MaterialText ON Material = _MaterialText.Material  -- association [0..*]
;