R_CollsPrmsToPayCollsSegmentTP

DDL: R_COLLSPRMSTOPAYCOLLSSEGMENTTP Type: view TRANSACTIONAL Package: ODATA_PROMISE_TO_PAY

Promise To Pay in Collections Segment

R_CollsPrmsToPayCollsSegmentTP is a Transactional CDS View that provides data about "Promise To Pay in Collections Segment" in SAP S/4HANA. It reads from 2 data sources (I_CollectionsInvoiceMemory, P_CollsPromiseToPayDraft) and exposes 51 fields with key fields CollectionSegment, PromiseToPayUUID, BranchAccount. It has 3 associations to related views. Part of development package ODATA_PROMISE_TO_PAY.

Data Sources (2)

SourceAliasJoin Type
I_CollectionsInvoiceMemory I_CollectionsInvoiceMemory inner
P_CollsPromiseToPayDraft P_CollsPromiseToPayDraft inner

Associations (3)

CardinalityTargetAliasCondition
[0..1] R_RblsMgmtUserContactCard _ChangedByContactCard $projection.CaseLastChangedBy = _ChangedByContactCard.ContactCardID
[0..1] R_RblsMgmtUserContactCard _CreatedByContactCard $projection.CaseCreatedBy = _CreatedByContactCard.ContactCardID
[0..1] R_RblsMgmtUserContactCard _ClosedByContactCard $projection.CaseClosedBy = _ClosedByContactCard.ContactCardID

Annotations (13)

NameValueLevelField
AbapCatalog.sqlViewName RCOLLSP2PSGMT view
AbapCatalog.preserveKey true view
AbapCatalog.compiler.compareFilter true view
EndUserText.label Promise To Pay in Collections Segment view
ObjectModel.representativeKey PromiseToPayUUID view
ObjectModel.usageType.dataClass #TRANSACTIONAL view
ObjectModel.usageType.sizeCategory #L view
ObjectModel.usageType.serviceQuality #C view
AccessControl.authorizationCheck #CHECK view
AccessControl.personalData.blocking #BLOCKED_DATA_EXCLUDED view
VDM.viewType #TRANSACTIONAL view
VDM.lifecycle.contract.type #SAP_INTERNAL_API view
ClientHandling.algorithm #SESSION_VARIABLE view

Fields (51)

KeyFieldSource TableSource FieldDescription
KEY CollectionSegment
KEY PromiseToPayUUID PromiseToPayUUID
KEY BranchAccount I_CollectionsInvoiceMemory BranchAccount
DraftUUID DraftUUID
CompanyCode I_CollsSgmtCompanyCodeAssgmt CompanyCode
Customer I_CollectionsInvoiceMemory Customer
ObjectType ObjectType
LinkedInvoiceKey LinkedInvoiceKey
PromisedAmount PromisedAmount
PaidAmount P_CollsPromiseToPayDraft PaidAmount
Currency Currency
DueDate P_CollsPromiseToPayDraft DueDate
PromiseToPayDate PromiseToPayDate
LastPaymentDate LastPaymentDate
PromiseToPayStatus PromiseToPayStatus
PromiseToPayLevel PromiseToPayLevel
PromiseToPayGivenByPersonName PromiseToPayGivenByPersonName
ContactPersonEmailAddress ContactPersonEmailAddress
ContactPersonPhoneNumber ContactPersonPhoneNumber
ContactPersonFaxNumber ContactPersonFaxNumber
ContactPersonFaxCountry ContactPersonFaxCountry
ContactPerson ContactPerson
NumberOfInstallments NumberOfInstallments
PaidOnScheduleAmount PaidOnScheduleAmount
PaidOffScheduleAmount PaidOffScheduleAmount
NextInstallmentDueDate NextInstallmentDueDate
NextInstallmentAmount NextInstallmentAmount
CaseID CaseID
CaseExternalReference CaseExternalReference
Prms2PToInvoiceGroupRefUUID Prms2PToInvoiceGroupRefUUID
CaseCreatedBy CaseCreatedBy
CaseCreatedOn CaseCreatedOn
CaseLastChangedBy CaseLastChangedBy
CaseLastChangedOn CaseLastChangedOn
CaseClosedBy CaseClosedBy
CaseClosedTime CaseClosedTime
IsActiveEntity IsActiveEntity
HasActiveEntity HasActiveEntity
DraftCreationDateTime DraftCreationDateTime
DraftLastChangedDateTime DraftLastChangedDateTime
CaseType CaseType
IsCleared IsCleared
_CaseAttribute _CaseAttribute
_ChangedByContactCard _ChangedByContactCard
_ClosedByContactCard _ClosedByContactCard
_CollsPromiseToPayStatus _CollsPromiseToPayStatus
_CompanyCode I_CollsSgmtCompanyCodeAssgmt _CompanyCode
_Country _Country
_CreatedByContactCard _CreatedByContactCard
_Currency _Currency
_Customer _Customer
@AbapCatalog: { sqlViewName: 'RCOLLSP2PSGMT',
                preserveKey: true,
                compiler: { compareFilter: true } }
@EndUserText: { label: 'Promise To Pay in Collections Segment' }
@ObjectModel: { representativeKey: 'PromiseToPayUUID',
                semanticKey:       [ 'CaseID' ],
                usageType:         { dataClass:      #TRANSACTIONAL,
                                     sizeCategory:   #L,
                                     serviceQuality: #C } }
@AccessControl: { authorizationCheck: #CHECK,
                  privilegedAssociations: ['_CreatedByContactCard',
                                           '_ChangedByContactCard',
                                           '_ClosedByContactCard' ],
                  personalData: { blocking: #BLOCKED_DATA_EXCLUDED } }
@Consumption.dbHints: [ 'USE_HEX_PLAN' ]
@VDM: { viewType:  #TRANSACTIONAL,
        lifecycle: { contract: { type: #SAP_INTERNAL_API } } }
@ClientHandling: { algorithm: #SESSION_VARIABLE }

define root view R_CollsPrmsToPayCollsSegmentTP
  as select distinct from I_CollsSgmtCompanyCodeAssgmt
    inner join            I_CollectionsInvoiceMemory on I_CollsSgmtCompanyCodeAssgmt.CompanyCode = I_CollectionsInvoiceMemory.CompanyCode
    inner join            P_CollsPromiseToPayDraft   on  I_CollsSgmtCompanyCodeAssgmt.CompanyCode = P_CollsPromiseToPayDraft.CompanyCode
                                                     and I_CollectionsInvoiceMemory.Customer      = P_CollsPromiseToPayDraft.Customer

  // Changed By Contact Card

  association [0..1] to R_RblsMgmtUserContactCard as _ChangedByContactCard on $projection.CaseLastChangedBy = _ChangedByContactCard.ContactCardID

  // Created By Contact Card

  association [0..1] to R_RblsMgmtUserContactCard as _CreatedByContactCard on $projection.CaseCreatedBy = _CreatedByContactCard.ContactCardID

  // Closed By Contact Card

  association [0..1] to R_RblsMgmtUserContactCard as _ClosedByContactCard  on $projection.CaseClosedBy = _ClosedByContactCard.ContactCardID

{

      // VDM Fields

  key cast( CollectionSegment as farp_collection_segment preserving type ) as CollectionSegment,
  key PromiseToPayUUID,
  key I_CollectionsInvoiceMemory.BranchAccount,
  
      DraftUUID,
      I_CollsSgmtCompanyCodeAssgmt.CompanyCode,
      I_CollectionsInvoiceMemory.Customer,

      ObjectType,
      LinkedInvoiceKey,

      @Semantics: { amount: { currencyCode: 'Currency' } }
      PromisedAmount,

      @Semantics: { amount: { currencyCode: 'Currency' } }
      P_CollsPromiseToPayDraft.PaidAmount,

      @Semantics: { currencyCode: true }
      Currency,

      P_CollsPromiseToPayDraft.DueDate,
      PromiseToPayDate,
      LastPaymentDate,
      PromiseToPayStatus,

      PromiseToPayLevel,
      PromiseToPayGivenByPersonName,

      @Semantics: { eMail: { address: true } }
      ContactPersonEmailAddress,

      @Semantics: { telephone: { type: [ #PREF ] } }
      ContactPersonPhoneNumber,

      @Semantics: { telephone: { type: [ #FAX ] } }
      ContactPersonFaxNumber,

      ContactPersonFaxCountry,
      ContactPerson,
      NumberOfInstallments,

      @Semantics: { amount: { currencyCode: 'Currency' } }
      PaidOnScheduleAmount,

      @Semantics: { amount: { currencyCode: 'Currency' } }
      PaidOffScheduleAmount,

      NextInstallmentDueDate,

      @Semantics: { amount: { currencyCode: 'Currency' } }
      NextInstallmentAmount,

      CaseID,
      CaseExternalReference,
      Prms2PToInvoiceGroupRefUUID,

      @ObjectModel: { foreignKey: { association: '_CreatedByContactCard' } }
      CaseCreatedBy,

      CaseCreatedOn,

      @ObjectModel: { foreignKey: { association: '_ChangedByContactCard' } }
      CaseLastChangedBy,

      CaseLastChangedOn,

      @ObjectModel: { foreignKey: { association: '_ClosedByContactCard' } }
      CaseClosedBy,

      CaseClosedTime,
      IsActiveEntity,
      HasActiveEntity,
      DraftCreationDateTime,
      DraftLastChangedDateTime,
      CaseType, 
      
      IsCleared,

      // Exposed Associations

      _CaseAttribute,
      _ChangedByContactCard,
      _ClosedByContactCard,
      _CollsPromiseToPayStatus,
      I_CollsSgmtCompanyCodeAssgmt._CompanyCode,
      _Country,
      _CreatedByContactCard,
      _Currency,
      _Customer

}