P_SrvcTransactionIssueItemC003

DDL: P_SRVCTRANSACTIONISSUEITEMC003 Type: view_entity COMPOSITE Package: CRMS4_ANALYTICS_SERVICE_ORDER

View for items with issue C001/C003 - Open Confirmations

P_SrvcTransactionIssueItemC003 is a Composite CDS View that provides data about "View for items with issue C001/C003 - Open Confirmations" in SAP S/4HANA. It reads from 2 data sources (I_ServiceDocumentItemSuccssr_2, I_ServiceDocumentItemEnhcd) and exposes 45 fields with key fields ServiceObjectType, ServiceDocument, ServiceDocumentItem, CustMgmtIssue, SrvcConfIssue. Part of development package CRMS4_ANALYTICS_SERVICE_ORDER.

Data Sources (2)

SourceAliasJoin Type
I_ServiceDocumentItemSuccssr_2 Link inner
I_ServiceDocumentItemEnhcd Successor inner

Annotations (4)

NameValueLevelField
AbapCatalog.dataMaintenance #DISPLAY_ONLY view
AccessControl.authorizationCheck #NOT_REQUIRED view
VDM.private true view
VDM.viewType #COMPOSITE view

Fields (45)

KeyFieldSource TableSource FieldDescription
KEY ServiceObjectType Item ServiceObjectType
KEY ServiceDocument Item ServiceDocument
KEY ServiceDocumentItem Item ServiceDocumentItem
KEY CustMgmtIssue
KEY SrvcConfIssue
ServiceDocumentType
Country
Region
ServiceRisk
ServiceDocumentProblemCategory
TransactionCurrency
SrvcOrdGrossAmount Item ServiceDocItemGrossAmount
Industry Item Industry
ServiceOrganization Item ServiceOrganization
SalesOrganization Item SalesOrganization
SalesOffice Item SalesOffice
SalesGroup Item SalesGroup
DistributionChannel Item DistributionChannel
Division Item Division
SoldToPartyCountry Item SoldToPartyCountry
SoldToPartyRegion Item SoldToPartyRegion
SoldToParty Item SoldToParty
ResponsibleEmployee Item ResponsibleEmployee
ContactPerson Item ContactPerson
ServiceTeam Item ServiceTeam
ServiceEmployee Item ServiceEmployee
ServiceDocItemRejectionReason Item ServiceDocItemRejectionReason
ServiceDocumentItemStatus Item ServiceDocumentItemStatus
ServiceDocumentItemHasError Item ServiceDocumentItemHasError
BillingBlockReason Item BillingBlockReason
ServiceDocItemBillingStatus Item ServiceDocItemBillingStatus
SrvcDocItmIsReleasedForBilling Item SrvcDocItmIsReleasedForBilling
SrvcDocItemTransferStatus Item SrvcDocItemTransferStatus
RefInHouseRepairIsExisting Item RefInHouseRepairIsExisting
RequestedServiceStartDateTime Item RequestedServiceStartDateTime
RequestedServiceEndDateTime Item RequestedServiceEndDateTime
PlannedServiceStartDateTime Item PlannedServiceStartDateTime
PlannedServiceEndDateTime Item PlannedServiceEndDateTime
SrvcDocItemSLADueByDateTime Item SrvcDocItemSLADueByDateTime
ResponseProfile Item ResponseProfile
ServiceProfile Item ServiceProfile
ServiceFirstResponseByDateTime Item ServiceFirstResponseByDateTime
RefBusinessSolutionOrder Item RefBusinessSolutionOrder
RefBusinessSolutionOrderItem Item RefBusinessSolutionOrderItem
_TransactionCurrency
@AbapCatalog:
    {
        dataMaintenance: #DISPLAY_ONLY
    }
@AccessControl.authorizationCheck: #NOT_REQUIRED
@VDM:
    {
        private: true,
        viewType: #COMPOSITE
    }
define view entity P_SrvcTransactionIssueItemC003
  as select distinct from I_ServiceDocumentItemEnhcd     as Item

    inner join            I_ServiceDocumentItemSuccssr_2 as Link      on  Link.ServiceDocumentItemObjectType  = Item.ServiceDocumentItemObjectType
                                                                      and Link.ServiceDocumentItemCharUUID    = Item.ServiceDocumentItemCharUUID
                                                                      and Link.ServiceDocumentItmRelationType = 'VONA'           // Predecessor/Sucessor Relationship

    inner join            I_ServiceDocumentItemEnhcd     as Successor on  Successor.ServiceDocumentItemObjectType = Link.ServiceDocItmSuccssrBusObjType
                                                                      and Successor.ServiceDocumentItemCharUUID   = Link.ServiceDocItmSuccssrCharUUID
                                                                      and Successor.ServiceObjectType             = 'BUS2000117' // Successor is a service confirmation

                                                                      and Successor.ServiceDocumentItemIsOpen     = 'X'          // Successor Item is open

{
  key Item.ServiceObjectType,
  key Item.ServiceDocument,
  key Item.ServiceDocumentItem,
  key cast ( 'C001' as crms4_service_issue )   as CustMgmtIssue,
  key cast ( 'C003' as crms4_srvc_conf_issue ) as SrvcConfIssue,

      Item._ServiceDocument.ServiceDocumentType,
      Item._ServiceDocument.SoldToPartyCountry as Country,
      Item._ServiceDocument.Region,
      Item._ServiceDocument.ServiceRisk,
      Item._ServiceDocument.ServiceDocumentProblemCategory,

      @ObjectModel.foreignKey.association: '_TransactionCurrency'
      Item._ServiceDocument.TransactionCurrency,

      @DefaultAggregation: #SUM
      @Semantics: { amount : {currencyCode: 'TransactionCurrency'} }
      Item.ServiceDocItemGrossAmount           as SrvcOrdGrossAmount,
      Item.Industry,

      // Organization Unit fields

      Item.ServiceOrganization,
      Item.SalesOrganization,
      Item.SalesOffice,
      Item.SalesGroup,
      Item.DistributionChannel,
      Item.Division,

      // Sales related fields (ex. BP)

      Item.SoldToPartyCountry,
      Item.SoldToPartyRegion,
      Item.SoldToParty,
      Item.ResponsibleEmployee,
      Item.ContactPerson,
      Item.ServiceTeam,
      Item.ServiceEmployee,

      // Status fields

      Item.ServiceDocItemRejectionReason,
      Item.ServiceDocumentItemStatus,
      Item.ServiceDocumentItemHasError,
      Item.BillingBlockReason,
      Item.ServiceDocItemBillingStatus,
      Item.SrvcDocItmIsReleasedForBilling,
      Item.SrvcDocItemTransferStatus,
      Item.RefInHouseRepairIsExisting,

      // Various attributes

      Item.RequestedServiceStartDateTime,
      Item.RequestedServiceEndDateTime,
      Item.PlannedServiceStartDateTime,
      Item.PlannedServiceEndDateTime,

      //SLA Dueby

      Item.SrvcDocItemSLADueByDateTime,
      Item.ResponseProfile,
      Item.ServiceProfile,
      Item.ServiceFirstResponseByDateTime,

      Item.RefBusinessSolutionOrder,
      Item.RefBusinessSolutionOrderItem,

      Item._ServiceDocument._TransactionCurrency
}
where
      Item.ServiceObjectType                           =  'BUS2000116' // Service Order

  and Item._ServiceDocument.ServiceDocumentIsRejected  <> 'X'          // Service transaction is not rejected

  and Item._ServiceDocument.ServiceDocumentIsReleased  =  'X'          // Service Order is Released

  and Item._ServiceDocument.ServiceDocumentIsQuotation <> 'X'          // Service Order is not a quotation

  and Item.RefInHouseRepairIsExisting                  is initial
  and Item._ServiceDocument.ServiceDocumentTemplateType = ' '