@VDM.private: true
@VDM.viewType: #CONSUMPTION
@AbapCatalog.sqlViewName: 'PRUVATINVCLRCH1'
@AbapCatalog.compiler.compareFilter: true
@AbapCatalog.preserveKey: true
@AccessControl.authorizationCheck: #NOT_REQUIRED
@ClientHandling.algorithm: #SESSION_VARIABLE
define view P_RU_VATInvoiceClearingChain1
as select from P_RU_BusPartnerClearingNotRvsd as Level1
inner join P_RU_BSET as bset on bset.CompanyCode = Level1.CompanyCode
and bset.AccountingDocument = Level1.AccountingDocument
and bset.FiscalYear = Level1.FiscalYear
and bset.TaxItem = '001'
{
Level1.CompanyCode,
Level1.AccountingDocument,
Level1.FiscalYear,
Level1.AccountingDocumentItem,
Level1.DebitCreditCode,
Level1.AccountType,
Level1.ClearingAccountingDocument,
Level1.ClearingFiscalYear,
Level1.ClearingInformationIndex,
Level1.ClearingInformationType,
Level1.ClearingAccountingDocument as ClearedAccountingDocument,
Level1.ClearingFiscalYear as ClearedFiscalYear,
'1' as ClearingLevel
}
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"P_RU_BSET",
"P_RU_BUSPARTNERCLEARINGNOTRVSD"
],
"ASSOCIATED":
[],
"BASE":
[],
"ANNO_REF":
[],
"SCALAR_FUNCTION":
[],
"VERSION":0,
"ANNOREF_EVALUATION_ERROR":""
}
}*/