P_SAFT_GeneralLedgerOneTimeBP

DDL: P_SAFT_GENERALLEDGERONETIMEBP SQL: PSAFTGENLEOTDBP Type: view COMPOSITE

P_SAFT_GeneralLedgerOneTimeBP is a Composite CDS View in SAP S/4HANA. It reads from 2 data sources (I_JournalEntryItem, P_SAFT_GLMaxBuPa) and exposes 7 fields with key fields CompanyCode, FiscalYear, AccountingDocument, LedgerGLLineItem, Ledger.

Data Sources (2)

SourceAliasJoin Type
I_JournalEntryItem a from
P_SAFT_GLMaxBuPa GLMaxBusinessPartner inner

Annotations (11)

NameValueLevelField
AbapCatalog.sqlViewName PSAFTGENLEOTDBP view
AbapCatalog.compiler.compareFilter true view
AbapCatalog.preserveKey true view
VDM.private true view
AccessControl.authorizationCheck #NOT_REQUIRED view
VDM.viewType #COMPOSITE view
ObjectModel.usageType.sizeCategory #XL view
ObjectModel.usageType.dataClass #MIXED view
ObjectModel.usageType.serviceQuality #P view
ClientHandling.algorithm #SESSION_VARIABLE view
AccessControl.personalData.blocking #NOT_REQUIRED view

Fields (7)

KeyFieldSource TableSource FieldDescription
KEY CompanyCode I_JournalEntryItem CompanyCode
KEY FiscalYear I_JournalEntryItem FiscalYear
KEY AccountingDocument I_JournalEntryItem AccountingDocument
KEY LedgerGLLineItem I_JournalEntryItem LedgerGLLineItem
KEY Ledger I_JournalEntryItem Ledger
BusinessPartnerType
BusinessPartnerNumber
@AbapCatalog.sqlViewName: 'PSAFTGENLEOTDBP'
@AbapCatalog.compiler.compareFilter: true
@AbapCatalog.preserveKey: true
@VDM.private: true
@AccessControl.authorizationCheck: #NOT_REQUIRED
@VDM.viewType: #COMPOSITE
@ObjectModel.usageType.sizeCategory: #XL
@ObjectModel.usageType.dataClass:  #MIXED
@ObjectModel.usageType.serviceQuality: #P
@ClientHandling.algorithm: #SESSION_VARIABLE
@AccessControl.personalData.blocking : #NOT_REQUIRED
define view P_SAFT_GeneralLedgerOneTimeBP
  as select from I_JournalEntryItem as a

    inner join   P_SAFT_GLMaxBuPa   as GLMaxBusinessPartner on  GLMaxBusinessPartner.CompanyCode        = a.CompanyCode
                                                            and GLMaxBusinessPartner.FiscalYear         = a.FiscalYear
                                                            and GLMaxBusinessPartner.AccountingDocument = a.AccountingDocument
                                                            and GLMaxBusinessPartner.LedgerGLLineItem   = a.LedgerGLLineItem
                                                            and GLMaxBusinessPartner.Ledger             = a.Ledger

{
  key a.CompanyCode                                                       as CompanyCode,
  key a.FiscalYear                                                        as FiscalYear,
  key a.AccountingDocument                                                as AccountingDocument,
  key a.LedgerGLLineItem                                                  as LedgerGLLineItem,
  key a.Ledger                                                            as Ledger,

      cast (case when a.Supplier is initial then '0001' else '0002' end as abap.char(4))              as BusinessPartnerType,

      case when a.Supplier is initial then a.Customer else a.Supplier end as BusinessPartnerNumber
}

where
  (
       a.FinancialAccountType       = 'D'
    or a.FinancialAccountType       = 'K'
  )
  and(
       a._Customer.IsOneTimeAccount = 'X'
    or a._Supplier.IsOneTimeAccount = 'X'
  )
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"I_CUSTOMER",
"I_JOURNALENTRYITEM",
"I_SUPPLIER",
"P_SAFT_GLMAXBUPA"
],
"ASSOCIATED":
[],
"BASE":
[],
"ANNO_REF":
[],
"SCALAR_FUNCTION":
[],
"VERSION":0,
"ANNOREF_EVALUATION_ERROR":""
}
}*/