P_PE_JournalEntryFSStructure

DDL: P_PE_JOURNALENTRYFSSTRUCTURE SQL: PPEJRNLEFSS Type: view CONSUMPTION

P_PE_JournalEntryFSStructure is a Consumption CDS View in SAP S/4HANA. It reads from 3 data sources (I_FinancialStatementStructure, P_PE_JournalEntryFSStructure2, I_JournalEntryItem) and exposes 6 fields with key fields CompanyCode, FiscalYear, AccountingDocument, Ledger, FinancialStatementHierarchy.

Data Sources (3)

SourceAliasJoin Type
I_FinancialStatementStructure FinancialStatement inner
P_PE_JournalEntryFSStructure2 FinancialStatementVersion2 from
I_JournalEntryItem JournalEntryItem inner

Annotations (9)

NameValueLevelField
AbapCatalog.sqlViewName PPEJRNLEFSS view
AbapCatalog.compiler.compareFilter true view
ClientHandling.algorithm #SESSION_VARIABLE view
AccessControl.authorizationCheck #NOT_REQUIRED view
VDM.private true view
VDM.viewType #CONSUMPTION view
ObjectModel.usageType.sizeCategory #XL view
ObjectModel.usageType.serviceQuality #D view
ObjectModel.usageType.dataClass #MIXED view

Fields (6)

KeyFieldSource TableSource FieldDescription
KEY CompanyCode I_JournalEntryItem CompanyCode
KEY FiscalYear I_JournalEntryItem FiscalYear
KEY AccountingDocument I_JournalEntryItem AccountingDocument
KEY Ledger I_JournalEntryItem Ledger
KEY FinancialStatementHierarchy I_FinancialStatementStructure FinancialStatementHierarchy
HierarchyParentNodeVal
@AbapCatalog.sqlViewName: 'PPEJRNLEFSS'
@AbapCatalog.compiler.compareFilter: true
@ClientHandling.algorithm: #SESSION_VARIABLE
@AccessControl.authorizationCheck: #NOT_REQUIRED
@VDM.private:true
@VDM.viewType: #CONSUMPTION
@ObjectModel.usageType.sizeCategory: #XL
@ObjectModel.usageType.serviceQuality: #D
@ObjectModel.usageType.dataClass: #MIXED

define view P_PE_JournalEntryFSStructure
  as select from P_PE_JournalEntryFSStructure2 as FinancialStatementVersion2

    inner join   I_JournalEntryItem            as JournalEntryItem on  JournalEntryItem.CompanyCode                 = FinancialStatementVersion2.CompanyCode
                                                                   and JournalEntryItem.FiscalYear                  = FinancialStatementVersion2.FiscalYear
                                                                   and JournalEntryItem.AccountingDocument          = FinancialStatementVersion2.AccountingDocument
                                                                   and JournalEntryItem.Ledger                      = FinancialStatementVersion2.Ledger
                                                                   and JournalEntryItem.AmountInTransactionCurrency = FinancialStatementVersion2.AmountInTransactionCurrency

    inner join   I_FinancialStatementStructure as FinancialStatement on  FinancialStatement.HierarchyNodeVal            = JournalEntryItem.GLAccount
                                                                     and FinancialStatement.FinancialStatementHierarchy = FinancialStatementVersion2.FinancialStatementHierarchy
{
  key JournalEntryItem.CompanyCode,
  key JournalEntryItem.FiscalYear,
  key JournalEntryItem.AccountingDocument,
  key JournalEntryItem.Ledger,
  key FinancialStatement.FinancialStatementHierarchy,

      min( FinancialStatement.HierarchyParentNodeVal ) as HierarchyParentNodeVal

}
where
  FinancialStatement.FinancialStatementNodeType = 'G'

group by
  JournalEntryItem.CompanyCode,
  JournalEntryItem.FiscalYear,
  JournalEntryItem.AccountingDocument,
  JournalEntryItem.Ledger,
  FinancialStatement.FinancialStatementHierarchy
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"I_FINANCIALSTATEMENTSTRUCTURE",
"I_JOURNALENTRYITEM",
"P_PE_JOURNALENTRYFSSTRUCTURE2"
],
"ASSOCIATED":
[],
"BASE":
[],
"ANNO_REF":
[],
"SCALAR_FUNCTION":
[],
"VERSION":0,
"ANNOREF_EVALUATION_ERROR":""
}
}*/