P_SrvcOrdItmWthSrvcContrDets
P_SrvcOrdItmWthSrvcContrDets is a Composite CDS View in SAP S/4HANA. It reads from 1 data source (I_ServiceDocumentItemEnhcd) and exposes 79 fields with key fields ServiceObjectType, ServiceOrder, ServiceDocumentItem, ServiceDocItmSuccssrCharUUID. It has 9 associations to related views.
Data Sources (1)
| Source | Alias | Join Type |
|---|---|---|
| I_ServiceDocumentItemEnhcd | I_ServiceDocumentItemEnhcd | from |
Associations (9)
| Cardinality | Target | Alias | Condition |
|---|---|---|---|
| [0..*] | P_SrvcOrdItmFUPSrvcContrDets | _SrvcOrdItmFUPSrvcContrDets | $projection.ServiceOrderItemCharUUID = _SrvcOrdItmFUPSrvcContrDets.ServiceOrderItemCharUUID |
| [0..*] | P_srvorditmfupsrvconfcontrdets | _SrvOrdItmFupSrvConfContDets | $projection.ServiceOrderItemCharUUID = _SrvOrdItmFupSrvConfContDets.ServiceOrderItemCharUUID |
| [0..1] | P_SrvcOrdItmFUPSrvcConfDets | _SrvcOrdItmFUPSrvcConfDets | $projection.ServiceOrderItemCharUUID = _SrvcOrdItmFUPSrvcConfDets.ServiceOrderItemCharUUID |
| [0..1] | I_ServiceDocumentRefObject | _MainRefObj | $projection.ServiceObjectType = _MainRefObj.ServiceObjectType and $projection.ServiceOrder = _MainRefObj.ServiceDocument and $projection.ServiceDocumentItem = _MainRefObj.ServiceDocumentItem and _MainRefObj.SrvcRefObjIsMainObject is not initial |
| [0..1] | I_CalendarDate | _Period | $projection.ServiceDocItemCreationDate = _Period.CalendarDate |
| [1..1] | I_Indicator | _ServiceContractItemIsActive | $projection.ServiceContractItemIsActive = _ServiceContractItemIsActive.IndicatorValue |
| [0..1] | I_ServiceDocumentEnhcd | _ServiceContract | _ServiceContract.ServiceObjectType = 'BUS2000112' and $projection.ServiceContract = _ServiceContract.ServiceDocument |
| [0..1] | I_ServiceDocument | _SolutionOrderVH | $projection.RefBusinessSolutionOrder = _SolutionOrderVH.ServiceDocument and _SolutionOrderVH.ServiceObjectType = 'BUS2000172' |
| [0..1] | I_RespyMgmtTeamHeaderDetail | _ServiceTeamVH | $projection.RespyMgmtServiceTeam = _ServiceTeamVH.RespyMgmtTeamID |
Annotations (9)
| Name | Value | Level | Field |
|---|---|---|---|
| AbapCatalog.sqlViewName | PSOITMWTHCONTRDT | view | |
| ClientHandling.algorithm | #SESSION_VARIABLE | view | |
| AbapCatalog.compiler.compareFilter | true | view | |
| AbapCatalog.preserveKey | true | view | |
| VDM.private | true | view | |
| VDM.viewType | #COMPOSITE | view | |
| ObjectModel.usageType.dataClass | #MIXED | view | |
| ObjectModel.usageType.serviceQuality | #D | view | |
| ObjectModel.usageType.sizeCategory | #XXL | view |
Fields (79)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | ServiceObjectType | ServiceObjectType | Object Type | |
| KEY | ServiceOrder | ServiceDocument | Transaction ID | |
| KEY | ServiceDocumentItem | ServiceDocumentItem | Service Document | |
| KEY | ServiceDocItmSuccssrCharUUID | _SrvOrdItmFupSrvConfContDets | ServiceDocItmSuccssrCharUUID | |
| ServiceOrderDescription | ServiceDocumentDescription | |||
| ServiceOrderType | ServiceDocumentType | Transaction Type | ||
| ServiceOrderItemCharUUID | ServiceDocumentItemCharUUID | |||
| ServiceOrderItemProduct | Product | Product Sold | ||
| ServiceOrderItemStatus | ServiceDocumentItemStatus | |||
| ServiceDocumentItemIsOpen | ServiceDocumentItemIsOpen | |||
| ServiceDocumentItemIsRejected | ServiceDocumentItemIsRejected | |||
| ServiceOrderItemQuantity | ServiceDocumentItemQuantity | |||
| ServiceOrderItemQuantityUnit | ServiceDocItemQuantityUnit | |||
| ServiceDocItemCreationDateTime | ServiceDocItemCreationDateTime | |||
| ServiceDocItemCreationDate | ServiceDocItemCreationDate | |||
| TransactionCurrency | TransactionCurrency | Transaction Currency | ||
| ServiceContractendasServiceContract | ||||
| ProfitCenterendasProfitCenter | ||||
| ControllingAreaendasControllingArea | ||||
| int4endasNmbrOfFUPServiceOrderItems | ||||
| int4endasNrOfSrvcOrdItmsWthoutContrRef | ||||
| Equipment | _MainRefObj | Equipment | Equipment check | |
| FunctionalLocation | _MainRefObj | FunctionalLocation | Object ID | |
| ServiceReferenceObjectType | _MainRefObj | ServiceReferenceObjectType | ||
| EquipmentCategory | ||||
| FunctionalLocationCategory | ||||
| TechnicalObjectType | ||||
| Material | ||||
| ConstructionMaterial | ||||
| SrvcOrdCreationQuarter | _Period | CalendarQuarter | Calendar Quarter | |
| SrvcOrdCreationMonth | _Period | CalendarMonth | Calendar Month | |
| SrvcOrdCreationYear | _Period | CalendarYear | Year | |
| CreationDateYearQuarter | _Period | YearQuarter | Year Quarter | |
| CreationDateYearMonth | _Period | YearMonth | Year Month | |
| RefBusinessSolutionOrder | RefBusinessSolutionOrder | |||
| SoldToParty | SoldToParty | Sold-to Party | ||
| SoldToPartyCountry | SoldToPartyCountry | |||
| SoldToPartyRegion | SoldToPartyRegion | |||
| Industry | Industry | Industry Sector | ||
| SalesOrganization | SalesOrganization | Sales Organization | ||
| SalesOffice | SalesOffice | Sales Office | ||
| SalesGroup | SalesGroup | Sales Group | ||
| DistributionChannel | DistributionChannel | RefDistCh-Cust/Mat. | ||
| Division | Division | Internal Division ID | ||
| RespEmployeeBusinessPartnerId | ResponsibleEmployee | Employee Resp. | ||
| RespyMgmtServiceTeam | RespyMgmtServiceTeam | |||
| TeamName | _ServiceTeamHeader | TeamName | ||
| RespyMgmtServiceTeamDesc | ||||
| _ServiceObjType | _ServiceObjType | |||
| _ServiceDocument | _ServiceDocument | |||
| _ServiceDocumentType | _ServiceDocumentType | |||
| _Product | _Product | |||
| _TransactionCurrency | _TransactionCurrency | |||
| _ServiceDocItemStatus | _ServiceDocItemStatus | |||
| _SrvcDocItmLifecycleStatus | _SrvcDocItmLifecycleStatus | |||
| _ServiceDocumentIsOpen | _ServiceDocumentIsOpen | |||
| _SalesUnit | _SalesUnit | |||
| _SrvcContrDets | _SrvcOrdItmFUPSrvcContrDets | |||
| _SrvcReferenceObjectType | _MainRefObj | _SrvcReferenceObjectType | ||
| _MainRefObj | _MainRefObj | |||
| _Equipment | _MainRefObj | _Equipment | ||
| _FunctionalLocation | _MainRefObj | _FunctionalLocation | ||
| _EquipmentCategory | ||||
| _Period | _Period | |||
| _SoldToParty | _SoldToParty | |||
| _SoldToPartyCountry | _SoldToPartyCountry | |||
| _SoldToPartyRegion | _SoldToPartyRegion | |||
| _Industry | _Industry | |||
| _SalesOrganization | _SalesOrganization | |||
| _SalesOffice | _SalesOffice | |||
| _SalesGroup | _SalesGroup | |||
| _DistributionChannel | _DistributionChannel | |||
| _Division | _Division | |||
| _RespEmployee | _RespEmployee | |||
| _ServiceContractItemIsActive | _ServiceContractItemIsActive | |||
| _ServiceContract | _ServiceContract | |||
| _SolutionOrderVH | _SolutionOrderVH | |||
| _ServiceTeamVH | _ServiceTeamVH | |||
| _ServiceTeamHeader | _ServiceTeamHeader |
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_SrvcOrdItmWthSrvcContrDets.
-- 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: PSOITMWTHCONTRDT
CREATE VIEW P_SrvcOrdItmWthSrvcContrDets AS
SELECT
ServiceObjectType,
ServiceDocument AS ServiceOrder,
ServiceDocumentItem,
_SrvOrdItmFupSrvConfContDets.ServiceDocItmSuccssrCharUUID AS ServiceDocItmSuccssrCharUUID,
ServiceDocumentDescription AS ServiceOrderDescription,
ServiceDocumentType AS ServiceOrderType,
ServiceDocumentItemCharUUID AS ServiceOrderItemCharUUID,
Product AS ServiceOrderItemProduct,
ServiceDocumentItemStatus AS ServiceOrderItemStatus,
ServiceDocumentItemIsOpen,
ServiceDocumentItemIsRejected,
ServiceDocumentItemQuantity AS ServiceOrderItemQuantity,
ServiceDocItemQuantityUnit AS ServiceOrderItemQuantityUnit,
ServiceDocItemCreationDateTime,
ServiceDocItemCreationDate,
TransactionCurrency,
case when _SrvcOrdItmFUPSrvcContrDets.ServiceContract is null then _SrvOrdItmFupSrvConfContDets.ServiceContract else _SrvcOrdItmFUPSrvcContrDets.ServiceContract end as ServiceContract AS ServiceContractendasServiceContract,
case when _SrvcOrdItmFUPSrvcContrDets.ProfitCenter is null then _SrvOrdItmFupSrvConfContDets.ProfitCenter else _SrvcOrdItmFUPSrvcContrDets.ProfitCenter end as ProfitCenter AS ProfitCenterendasProfitCenter,
case when _SrvcOrdItmFUPSrvcContrDets.ControllingArea is null then _SrvOrdItmFupSrvConfContDets.ControllingArea else _SrvcOrdItmFUPSrvcContrDets.ControllingArea end as ControllingArea AS ControllingAreaendasControllingArea,
case when _SrvcOrdItmFUPSrvcContrDets.ServiceContract is not null or _SrvOrdItmFupSrvConfContDets.ServiceContract is not null then cast (1 as abap.int4) else cast (0 as abap.int4) end as NmbrOfFUPServiceOrderItems AS int4endasNmbrOfFUPServiceOrderItems,
case when _SrvcOrdItmFUPSrvcContrDets.ServiceContract is null and _SrvOrdItmFupSrvConfContDets.ServiceContract is null then cast (1 as abap.int4) else cast (0 as abap.int4) end as NrOfSrvcOrdItmsWthoutContrRef AS int4endasNrOfSrvcOrdItmsWthoutContrRef,
_MainRefObj.Equipment AS Equipment,
_MainRefObj.FunctionalLocation AS FunctionalLocation,
_MainRefObj.ServiceReferenceObjectType AS ServiceReferenceObjectType,
_MainRefObj._Equipment.EquipmentCategory AS EquipmentCategory,
_MainRefObj._FunctionalLocation.FunctionalLocationCategory AS FunctionalLocationCategory,
_MainRefObj._Equipment.TechnicalObjectType AS TechnicalObjectType,
_MainRefObj._Equipment.Material AS Material,
_MainRefObj._FunctionalLocation.ConstructionMaterial AS ConstructionMaterial,
_Period.CalendarQuarter AS SrvcOrdCreationQuarter,
_Period.CalendarMonth AS SrvcOrdCreationMonth,
_Period.CalendarYear AS SrvcOrdCreationYear,
_Period.YearQuarter AS CreationDateYearQuarter,
_Period.YearMonth AS CreationDateYearMonth,
RefBusinessSolutionOrder,
SoldToParty,
SoldToPartyCountry,
SoldToPartyRegion,
Industry,
SalesOrganization,
SalesOffice,
SalesGroup,
DistributionChannel,
Division,
ResponsibleEmployee AS RespEmployeeBusinessPartnerId,
RespyMgmtServiceTeam,
_ServiceTeamHeader.TeamName AS TeamName,
_ServiceTeamHeader._TeamDescription.TeamDescription AS RespyMgmtServiceTeamDesc,
_MainRefObj._SrvcReferenceObjectType AS _SrvcReferenceObjectType,
_MainRefObj._Equipment AS _Equipment,
_MainRefObj._FunctionalLocation AS _FunctionalLocation,
_MainRefObj._Equipment._EquipmentCategory AS _EquipmentCategory
FROM I_ServiceDocumentItemEnhcd
LEFT OUTER JOIN P_SrvcOrdItmFUPSrvcContrDets AS _SrvcOrdItmFUPSrvcContrDets ON ServiceOrderItemCharUUID = _SrvcOrdItmFUPSrvcContrDets.ServiceOrderItemCharUUID -- association [0..*]
LEFT OUTER JOIN P_srvorditmfupsrvconfcontrdets AS _SrvOrdItmFupSrvConfContDets ON ServiceOrderItemCharUUID = _SrvOrdItmFupSrvConfContDets.ServiceOrderItemCharUUID -- association [0..*]
LEFT OUTER JOIN P_SrvcOrdItmFUPSrvcConfDets AS _SrvcOrdItmFUPSrvcConfDets ON ServiceOrderItemCharUUID = _SrvcOrdItmFUPSrvcConfDets.ServiceOrderItemCharUUID -- association [0..1]
LEFT OUTER JOIN I_ServiceDocumentRefObject AS _MainRefObj ON ServiceObjectType = _MainRefObj.ServiceObjectType AND ServiceOrder = _MainRefObj.ServiceDocument AND ServiceDocumentItem = _MainRefObj.ServiceDocumentItem AND _MainRefObj.SrvcRefObjIsMainObject is not initial -- association [0..1]
LEFT OUTER JOIN I_CalendarDate AS _Period ON ServiceDocItemCreationDate = _Period.CalendarDate -- association [0..1]
LEFT OUTER JOIN I_Indicator AS _ServiceContractItemIsActive ON ServiceContractItemIsActive = _ServiceContractItemIsActive.IndicatorValue -- association [1..1]
LEFT OUTER JOIN I_ServiceDocumentEnhcd AS _ServiceContract ON _ServiceContract.ServiceObjectType = 'BUS2000112' AND ServiceContract = _ServiceContract.ServiceDocument -- association [0..1]
LEFT OUTER JOIN I_ServiceDocument AS _SolutionOrderVH ON RefBusinessSolutionOrder = _SolutionOrderVH.ServiceDocument AND _SolutionOrderVH.ServiceObjectType = 'BUS2000172' -- association [0..1]
LEFT OUTER JOIN I_RespyMgmtTeamHeaderDetail AS _ServiceTeamVH ON RespyMgmtServiceTeam = _ServiceTeamVH.RespyMgmtTeamID -- association [0..1]
;
Learn More
- VDM (Virtual Data Model) in SAP S/4HANA Explained
- Types of CDS Views: Basic, Composite, Consumption, and Transactional
- CDS View Annotations — A Complete Guide
- What Is a CDS View in SAP S/4HANA?
- SAP Tables vs CDS Views — Key Differences
- Understanding Data Lineage in SAP S/4HANA
- 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
- BSEG to ACDOCA: The Universal Journal Migration
- Business Partner Migration: KNA1/LFA1 to BUT000
- Material Document Migration: MSEG/MKPF to MATDOC
- How to Find the Right CDS View for an SAP Table
- BW Extractor to CDS View Migration Guide
- S/4HANA CDS View Deprecation: What You Need to Know
- ABAP CDS View Tutorial — From Basics to Real-World Examples
- RAP and CDS Views — Building Transactional Apps in SAP S/4HANA
- Sales Document Status Migration: VBUP/VBUK Removal in S/4HANA
- CO Tables in S/4HANA: COEP, COBK, COSS, COSP to ACDOCA