C_RO_StRpDomesticSlsPurListC

DDL: C_RO_STRPDOMESTICSLSPURLISTC SQL: CRODSPLISTC Type: view CONSUMPTION

Romania Domestic Sales and Purchase List - Cube

C_RO_StRpDomesticSlsPurListC is a Consumption CDS View (Cube) that provides data about "Romania Domestic Sales and Purchase List - Cube" in SAP S/4HANA. It reads from 10 data sources and exposes 55 fields with key fields CompanyCode, FiscalYear, TaxItem, StatryRptgEntity, StatryRptCategory.

Data Sources (10)

SourceAliasJoin Type
I_RO_BusinessPartnerTaxType bpty left_outer
I_Customer C left_outer
I_Country CustomerCountry left_outer
I_DomainFixedValue dv left_outer
I_BrexitProtocolValidity niprot inner
I_OperationalAcctgDocItem oadi left_outer
P_niprotocolregions P_niprotocolregions left_outer
I_JournalEntry ReverseDocumentJournalEntry left_outer
I_Supplier S left_outer
I_Country SupplierCountry left_outer

Parameters (3)

NameTypeDefault
P_StatryRptgEntity srf_reporting_entity
P_StatryRptCategory srf_rep_cat_id
P_StatryRptRunID srf_report_run_id

Annotations (13)

NameValueLevelField
VDM.viewType #CONSUMPTION view
Analytics.dataCategory #CUBE view
AbapCatalog.sqlViewName CRODSPLISTC view
AbapCatalog.compiler.compareFilter true view
EndUserText.label Romania Domestic Sales and Purchase List - Cube view
AccessControl.authorizationCheck #CHECK view
AccessControl.personalData.blocking #BLOCKED_DATA_INCLUDED view
ClientHandling.algorithm #SESSION_VARIABLE view
ObjectModel.usageType.sizeCategory #XL view
ObjectModel.usageType.serviceQuality #D view
ObjectModel.usageType.dataClass #MIXED view
Metadata.allowExtensions true view
Analytics.internalName #LOCAL view

Fields (55)

KeyFieldSource TableSource FieldDescription
KEY CompanyCode strp CompanyCode Receiver Company Code
KEY FiscalYear strp FiscalYear G/L Fiscal Year
KEY TaxItem strp TaxItem Tax Item
KEY StatryRptgEntity StatryRptgEntity Reporting Entity
KEY StatryRptCategory StatryRptCategory Report ID
KEY StatryRptRunID StatryRptRunID Report Run ID
KEY TaxCode strp TaxCode Tax Code
KEY TransactionTypeDetermination strp TransactionTypeDetermination Transaction Key
KEY TaxBox strp TaxBox Tax.Bs.Gp.No.
KEY TaxDeclnAmountType TaxDeclnAmountType
KEY ValidFrom
Reference1IDByBusinessPartner _DebtorCreditorRblsPyblsItem Reference1IDByBusinessPartner Reference Key 1
AccountingDocumentItem
TaxGroup TaxGroup Tax Group
AccountingDocumentHeaderText _AccountingDocument AccountingDocumentHeaderText Doc.Header Text
TransactionCode _AccountingDocument TransactionCode Transaction Code
InvoiceDocumentNumber strp AccountingDocument Journal Entry
TaxNumber6endasstcegasVATRegistration
CountryendasCountry
RegionendasRegion
TaxNumber4endasstcd4asTaxNumber4
TaxNumber5endasstcd5asTaxNumber5
TaxNumber6endasTaxNumber6
PostingDate strp PostingDate Posting Date for GR
DocumentDate strp DocumentDate Journal Entry Date
TaxReportingDate strp TaxReportingDate Tax Reporting Date
ReportingDate ReportingDate
FiscalPeriod strp FiscalPeriod Tax period
AccountingDocumentType strp AccountingDocumentType Journal Entry Type
DocumentReferenceID strp DocumentReferenceID Reference
CompanyCodeCountry CompanyCodeCountry Reporting Ctry/Reg.
ReportingCountry ReportingCountry
TaxReturnCountry TaxReturnCountry Reporting C/R
ExchangeRate strp ExchangeRate Exchange rate
TaxRate10endasTaxRate
GLAccount strp GLAccount General Ledger
BusinessPlace strp BusinessPlace Business place
TaxJurisdiction strp TaxJurisdiction Tax Jurisdiction
LowestLevelTaxJurisdiction LowestLevelTaxJurisdiction Jurisdict. Code
TaxNumber1
TaxNumber2
TaxNumber3 strp TaxNumber3
BusinessPartner strp BusinessPartner Issuing Authority
Supplier strp Supplier Supplier
Customer strp Customer Sold-to Party
CustomerSupplierAddress
IsReversal strp IsReversal Reversal doc.
IsReversed strp IsReversed Reversed?
TaxType strp TaxType Tax Type
TargetTaxCode TargetTaxCode
ReportingCurrency ReportingCurrency Currency
TaxGroupFreeClassification TaxGroupFreeClassification
TaxIsNotDeductible TaxIsNotDeductible Non-Deductible
CityName _OneTimeAccountBP001 CityName Name
_OneTimeAccountBP001 _OneTimeAccountBP001

Derived SQL interpretation, reconstructed from the parsed view metadata (data sources, associations, and field mappings). SAP annotations are omitted and the structure is reformulated as SQL — this is a functional approximation, not the verbatim SAP source.

-- Derived SQL interpretation of CDS view C_RO_StRpDomesticSlsPurListC.
-- Reconstructed from parsed metadata (data sources, associations, fields).
-- SAP annotations are omitted and the structure is reformulated as SQL;
-- this is a functional approximation, not the verbatim SAP source. Some join
-- conditions may be unavailable and a few CDS constructs are kept as-is.
-- SQL view name: CRODSPLISTC
-- Parameters: P_StatryRptgEntity : srf_reporting_entity, P_StatryRptCategory : srf_rep_cat_id, P_StatryRptRunID : srf_report_run_id

CREATE VIEW C_RO_StRpDomesticSlsPurListC AS
SELECT
  strp.CompanyCode AS CompanyCode,
  strp.FiscalYear AS FiscalYear,
  strp.TaxItem AS TaxItem,
  StatryRptgEntity,
  StatryRptCategory,
  StatryRptRunID,
  strp.TaxCode AS TaxCode,
  strp.TransactionTypeDetermination AS TransactionTypeDetermination,
  strp.TaxBox AS TaxBox,
  TaxDeclnAmountType,
  cast( strp.TaxBoxStrucValidityStartDate as begda) AS ValidFrom,
  _DebtorCreditorRblsPyblsItem.Reference1IDByBusinessPartner AS Reference1IDByBusinessPartner,
  cast('000' as farp_buzei) AS AccountingDocumentItem,
  TaxGroup,
  _AccountingDocument.AccountingDocumentHeaderText AS AccountingDocumentHeaderText,
  _AccountingDocument.TransactionCode AS TransactionCode,
  strp.AccountingDocument AS InvoiceDocumentNumber,
  cast((case when bpty.VATRegistration <> '' and bpty.VATRegistration is not null then bpty.VATRegistration when _DebtorCreditorRblsPyblsItem.VATRegistration <> '' and _DebtorCreditorRblsPyblsItem.VATRegistration is not null then _DebtorCreditorRblsPyblsItem.VATRegistration when _DebtorCreditorRblsPyblsItem._Supplier.VATRegistration <> '' and _DebtorCreditorRblsPyblsItem._Supplier.VATRegistration is not null then _DebtorCreditorRblsPyblsItem._Supplier.VATRegistration when _DebtorCreditorRblsPyblsItem._Customer.VATRegistration <> '' and _DebtorCreditorRblsPyblsItem._Customer.VATRegistration is not null then _DebtorCreditorRblsPyblsItem._Customer.VATRegistration when _OneTimeAccountBP001.TaxID1 <> '' and _OneTimeAccountBP001.TaxID1 is not null then _OneTimeAccountBP001.TaxID1 when strp.TaxNumber1 <> '' and strp.TaxNumber1 is not null then strp.TaxNumber1 when strp.TaxNumber2 <> '' and strp.TaxNumber2 is not null then strp.TaxNumber2 when strp.TaxNumber3 <> '' and strp.TaxNumber3 is not null then strp.TaxNumber3 when strp.Supplier <> '' and SupplierCountry.CountryISOCode = 'GB' and niregions.region is not null and ReportingDate between niprot.BrexitProtocolValidFromDate and niprot.BrexitProtocolValidToDate then S.TaxNumber6 when strp.Customer <> '' and CustomerCountry.CountryISOCode = 'GB' and niregions.region is not null and ReportingDate between niprot.BrexitProtocolValidFromDate and niprot.BrexitProtocolValidToDate then C.TaxNumber6 end) as stceg) as VATRegistration AS TaxNumber6endasstcegasVATRegistration,
  case when strp._DebtorCreditorRblsPyblsItem._Customer.Customer <> '' then coalesce(_OneTimeAccountBP001.Country, strp._DebtorCreditorRblsPyblsItem._Customer.Country) when strp._DebtorCreditorRblsPyblsItem._Supplier.Supplier <> '' then coalesce(_OneTimeAccountBP001.Country ,strp._DebtorCreditorRblsPyblsItem._Supplier.Country) end as Country AS CountryendasCountry,
  case when strp._DebtorCreditorRblsPyblsItem._Customer.Customer <> '' then coalesce(_OneTimeAccountBP001.Region, strp._DebtorCreditorRblsPyblsItem._Customer.Region) when strp._DebtorCreditorRblsPyblsItem._Supplier.Supplier <> '' then coalesce(_OneTimeAccountBP001.Region ,strp._DebtorCreditorRblsPyblsItem._Supplier.Region) end as Region AS RegionendasRegion,
  cast(case when strp._DebtorCreditorRblsPyblsItem._Customer.Customer <> '' then coalesce(_OneTimeAccountBP001.TaxID4, strp._DebtorCreditorRblsPyblsItem._Customer.TaxNumber4) when strp._DebtorCreditorRblsPyblsItem._Supplier.Supplier <> '' then coalesce(_OneTimeAccountBP001.TaxID4 ,strp._DebtorCreditorRblsPyblsItem._Supplier.TaxNumber4) end as stcd4) as TaxNumber4 AS TaxNumber4endasstcd4asTaxNumber4,
  cast(case when strp._DebtorCreditorRblsPyblsItem._Customer.Customer <> '' then coalesce(_OneTimeAccountBP001.TaxID5, strp._DebtorCreditorRblsPyblsItem._Customer.TaxNumber5) when strp._DebtorCreditorRblsPyblsItem._Supplier.Supplier <> '' then coalesce(_OneTimeAccountBP001.TaxID5 ,strp._DebtorCreditorRblsPyblsItem._Supplier.TaxNumber5) end as stcd5) as TaxNumber5 AS TaxNumber5endasstcd5asTaxNumber5,
  case when strp._DebtorCreditorRblsPyblsItem._Customer.Customer <> '' then strp._DebtorCreditorRblsPyblsItem._Customer.TaxNumber6 when strp._DebtorCreditorRblsPyblsItem._Supplier.Supplier <> '' then strp._DebtorCreditorRblsPyblsItem._Supplier.TaxNumber6 end as TaxNumber6 AS TaxNumber6endasTaxNumber6,
  strp.PostingDate AS PostingDate,
  strp.DocumentDate AS DocumentDate,
  strp.TaxReportingDate AS TaxReportingDate,
  ReportingDate,
  strp.FiscalPeriod AS FiscalPeriod,
  strp.AccountingDocumentType AS AccountingDocumentType,
  strp.DocumentReferenceID AS DocumentReferenceID,
  CompanyCodeCountry,
  ReportingCountry,
  TaxReturnCountry,
  strp.ExchangeRate AS ExchangeRate,
  case when TaxRate < 0 then division( -1 * strp.TaxRate , 1, 0) else division(strp.TaxRate , 1, 0) end as TaxRate AS TaxRate10endasTaxRate,
  strp.GLAccount AS GLAccount,
  strp.BusinessPlace AS BusinessPlace,
  strp.TaxJurisdiction AS TaxJurisdiction,
  LowestLevelTaxJurisdiction,
  cast(strp.TaxNumber1 as stcd1) AS TaxNumber1,
  cast(strp.TaxNumber2 as stcd2) AS TaxNumber2,
  strp.TaxNumber3 AS TaxNumber3,
  strp.BusinessPartner AS BusinessPartner,
  strp.Supplier AS Supplier,
  strp.Customer AS Customer,
  cast(CustomerSupplierAddress as glo_address) AS CustomerSupplierAddress,
  strp.IsReversal AS IsReversal,
  strp.IsReversed AS IsReversed,
  strp.TaxType AS TaxType,
  TargetTaxCode,
  ReportingCurrency,
  TaxGroupFreeClassification,
  TaxIsNotDeductible,
  _OneTimeAccountBP001.CityName AS CityName
LEFT OUTER JOIN I_OperationalAcctgDocItem AS oadi ON /* join condition not captured in parsed metadata */
LEFT OUTER JOIN I_DomainFixedValue AS dv ON /* join condition not captured in parsed metadata */
LEFT OUTER JOIN I_RO_BusinessPartnerTaxType AS bpty ON /* join condition not captured in parsed metadata */
LEFT OUTER JOIN I_Supplier AS S ON /* join condition not captured in parsed metadata */
LEFT OUTER JOIN I_Customer AS C ON /* join condition not captured in parsed metadata */
LEFT OUTER JOIN I_Country AS SupplierCountry ON /* join condition not captured in parsed metadata */
LEFT OUTER JOIN I_Country AS CustomerCountry ON /* join condition not captured in parsed metadata */
INNER JOIN I_BrexitProtocolValidity AS niprot ON /* join condition not captured in parsed metadata */
LEFT OUTER JOIN P_niprotocolregions ON /* join condition not captured in parsed metadata */
LEFT OUTER JOIN I_JournalEntry AS ReverseDocumentJournalEntry ON /* join condition not captured in parsed metadata */
;