P_KZ_VATRetForeignDocRenew
Section 5 for old VAT Return KZ
P_KZ_VATRetForeignDocRenew is a Composite CDS View that provides data about "Section 5 for old VAT Return KZ" in SAP S/4HANA. It reads from 1 data source (P_KZ_DSVATRetForiegnDocRenew1) and exposes 47 fields. It has 1 association to related views. Part of development package GLO_FIN_FI_KZ.
Data Sources (1)
| Source | Alias | Join Type |
|---|---|---|
| P_KZ_DSVATRetForiegnDocRenew1 | P_KZ_DSVATRetForiegnDocRenew1 | from |
Parameters (4)
| Name | Type | Default |
|---|---|---|
| P_VATReturnVersion | j_3rvatdversion | |
| P_TaxItemGroupingVersion | verstax | |
| P_ReportingPeriodStartDate | datum | |
| P_ReportingPeriodEndDate | datum |
Associations (1)
| Cardinality | Target | Alias | Condition |
|---|---|---|---|
| [0..1] | I_KZ_BusinessPartnerContract | _Contract | BusinessPartnerItem.AssignmentReference = _Contract.AssignmentReference and ForeignDoc.CompanyCode = _Contract.CompanyCode |
Annotations (6)
| Name | Value | Level | Field |
|---|---|---|---|
| AbapCatalog.sqlViewName | PKZVATRETFORREN | view | |
| ClientHandling.algorithm | #SESSION_VARIABLE | view | |
| AccessControl.authorizationCheck | #NOT_REQUIRED | view | |
| VDM.viewType | #COMPOSITE | view | |
| VDM.private | true | view | |
| AbapCatalog.compiler.compareFilter | true | view |
Fields (47)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| CompanyCode | ForeignDoc | CompanyCode | Receiver Company Code | |
| AccountingDocument | ForeignDoc | AccountingDocument | Journal Entry | |
| FiscalYear | ForeignDoc | FiscalYear | G/L Fiscal Year | |
| TaxBaseAmountInCoCodeCrcy | BusinessPartnerItem | AmountInCompanyCodeCurrency | Local Crcy Amt | |
| TaxAmountInCoCodeCrcy | ForeignDoc | TaxAmountInCoCodeCrcy | Tax Amount in Company Code Currency | |
| PostingDate | ForeignDoc | PostingDate | Posting Date for GR | |
| TaxReportingDate | ForeignDoc | TaxReportingDate | Tax Reporting Date | |
| DocumentDate | ForeignDoc | DocumentDate | Journal Entry Date | |
| AccountingDocumentType | ForeignDoc | AccountingDocumentType | Journal Entry Type | |
| IsReversal | ForeignDoc | IsReversal | Reversal doc. | |
| IsReversed | ForeignDoc | IsReversed | Reversed? | |
| OriginalReferenceDocument | ForeignDoc | OriginalReferenceDocument | Reference Key | |
| ReferenceDocumentType | ForeignDoc | ReferenceDocumentType | Reference Document Type | |
| DocumentReferenceID | ForeignDoc | DocumentReferenceID | Reference | |
| BusinessTransactionType | ForeignDoc | BusinessTransactionType | Bus.transaction | |
| SenderLogicalSystem | ForeignDoc | SenderLogicalSystem | Sender Logical System | |
| CompanyCodeCurrency | ForeignDoc | CompanyCodeCurrency | Local Currency | |
| Currency | Currency | Valuation Crcy | ||
| VATToBePaid | ForeignDoc | TaxBaseAmountInCoCodeCrcy | TxBaseAmt CoCodeCrcy | |
| SupplierName | SupplierData | SupplierName | Supplier Name | |
| Country | Country | CountryThreeDigitISOCode | ||
| TaxNumber1 | RootSuplierData | TaxNumber1 | VAT Reg. No. | |
| TaxCode | ForeignDoc | TaxCode | Tax Code | |
| AccountingDocumentItem | ForeignDoc | AccountingDocumentItem | Posting View Item | |
| FiscalPeriod | ForeignDoc | FiscalPeriod | Tax period | |
| ControllingArea | BusinessPartnerItem | ControllingArea | Controlling Area | |
| Segment | BusinessPartnerItem | Segment | Segment number | |
| ProfitCenter | BusinessPartnerItem | ProfitCenter | Profit Center | |
| CostCenter | BusinessPartnerItem | CostCenter | Cost Center | |
| BusinessArea | BusinessPartnerItem | BusinessArea | Business Area | |
| Supplier | BusinessPartnerItem | Supplier | Supplier | |
| Customer | BusinessPartnerItem | Customer | Sold-to Party | |
| MasterFixedAsset | BusinessPartnerItem | MasterFixedAsset | Fixed Asset | |
| FixedAsset | BusinessPartnerItem | FixedAsset | Sub-number | |
| AssetClass | BusinessPartnerItem | AssetClass | Asset Class | |
| AssignmentReference | BusinessPartnerItem | AssignmentReference | Assignment Reference | |
| Plant | BusinessPartnerItem | Plant | Valuation Area | |
| InventoryValuationType | BusinessPartnerItem | InventoryValuationType | Valuation Type | |
| ValuationArea | BusinessPartnerItem | ValuationArea | Valuation Area | |
| Product | BusinessPartnerItem | Product | Product Sold | |
| FunctionalArea | BusinessPartnerItem | FunctionalArea | Sendr Fctl Area | |
| Material | BusinessPartnerItem | Material | Vehicle Model | |
| AccountingDocumentCategory | ForeignDoc | AccountingDocumentCategory | Journal Entry Category | |
| KZ_TaxTurnoverCode | KZ_TaxTurnoverCode | |||
| TaxGroupOperation | ForeignDoc | TaxGroupOperation | ||
| DebitCreditCode | ForeignDoc | DebitCreditCode | Single-Character Flag | |
| _Contract | _Contract |
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 P_KZ_VATRetForeignDocRenew.
-- 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: PKZVATRETFORREN
-- Parameters: P_VATReturnVersion : j_3rvatdversion, P_TaxItemGroupingVersion : verstax, P_ReportingPeriodStartDate : datum, P_ReportingPeriodEndDate : datum
CREATE VIEW P_KZ_VATRetForeignDocRenew AS
SELECT
ForeignDoc.CompanyCode AS CompanyCode,
ForeignDoc.AccountingDocument AS AccountingDocument,
ForeignDoc.FiscalYear AS FiscalYear,
BusinessPartnerItem.AmountInCompanyCodeCurrency AS TaxBaseAmountInCoCodeCrcy,
ForeignDoc.TaxAmountInCoCodeCrcy AS TaxAmountInCoCodeCrcy,
ForeignDoc.PostingDate AS PostingDate,
ForeignDoc.TaxReportingDate AS TaxReportingDate,
ForeignDoc.DocumentDate AS DocumentDate,
ForeignDoc.AccountingDocumentType AS AccountingDocumentType,
ForeignDoc.IsReversal AS IsReversal,
ForeignDoc.IsReversed AS IsReversed,
ForeignDoc.OriginalReferenceDocument AS OriginalReferenceDocument,
ForeignDoc.ReferenceDocumentType AS ReferenceDocumentType,
ForeignDoc.DocumentReferenceID AS DocumentReferenceID,
ForeignDoc.BusinessTransactionType AS BusinessTransactionType,
ForeignDoc.SenderLogicalSystem AS SenderLogicalSystem,
ForeignDoc.CompanyCodeCurrency AS CompanyCodeCurrency,
Currency,
ForeignDoc.TaxBaseAmountInCoCodeCrcy AS VATToBePaid,
SupplierData.SupplierName AS SupplierName,
Country.CountryThreeDigitISOCode AS Country,
RootSuplierData.TaxNumber1 AS TaxNumber1,
ForeignDoc.TaxCode AS TaxCode,
ForeignDoc.AccountingDocumentItem AS AccountingDocumentItem,
ForeignDoc.FiscalPeriod AS FiscalPeriod,
BusinessPartnerItem.ControllingArea AS ControllingArea,
BusinessPartnerItem.Segment AS Segment,
BusinessPartnerItem.ProfitCenter AS ProfitCenter,
BusinessPartnerItem.CostCenter AS CostCenter,
BusinessPartnerItem.BusinessArea AS BusinessArea,
BusinessPartnerItem.Supplier AS Supplier,
BusinessPartnerItem.Customer AS Customer,
BusinessPartnerItem.MasterFixedAsset AS MasterFixedAsset,
BusinessPartnerItem.FixedAsset AS FixedAsset,
BusinessPartnerItem.AssetClass AS AssetClass,
BusinessPartnerItem.AssignmentReference AS AssignmentReference,
BusinessPartnerItem.Plant AS Plant,
BusinessPartnerItem.InventoryValuationType AS InventoryValuationType,
BusinessPartnerItem.ValuationArea AS ValuationArea,
BusinessPartnerItem.Product AS Product,
BusinessPartnerItem.FunctionalArea AS FunctionalArea,
BusinessPartnerItem.Material AS Material,
ForeignDoc.AccountingDocumentCategory AS AccountingDocumentCategory,
KZ_TaxTurnoverCode,
ForeignDoc.TaxGroupOperation AS TaxGroupOperation,
ForeignDoc.DebitCreditCode AS DebitCreditCode
FROM P_KZ_DSVATRetForiegnDocRenew1
LEFT OUTER JOIN I_KZ_BusinessPartnerContract AS _Contract ON BusinessPartnerItem.AssignmentReference = _Contract.AssignmentReference AND ForeignDoc.CompanyCode = _Contract.CompanyCode -- association [0..1]
;
Learn More
- VDM (Virtual Data Model) in SAP S/4HANA Explained
- Types of CDS Views: Basic, Composite, Consumption, and Transactional
- CDS View Annotations — A Complete Guide
- What Is a CDS View in SAP S/4HANA?
- SAP Tables vs CDS Views — Key Differences
- Understanding Data Lineage in SAP S/4HANA
- CDS View Field Mapping and Associations
- Understanding the SAP S/4HANA Data Model
- CDS View Extensions and Custom Fields in SAP S/4HANA
- Released APIs and Stability Contracts in SAP S/4HANA
- BSEG to ACDOCA: The Universal Journal Migration
- Business Partner Migration: KNA1/LFA1 to BUT000
- Material Document Migration: MSEG/MKPF to MATDOC
- How to Find the Right CDS View for an SAP Table
- BW Extractor to CDS View Migration Guide
- S/4HANA CDS View Deprecation: What You Need to Know
- ABAP CDS View Tutorial — From Basics to Real-World Examples
- RAP and CDS Views — Building Transactional Apps in SAP S/4HANA
- Sales Document Status Migration: VBUP/VBUK Removal in S/4HANA
- CO Tables in S/4HANA: COEP, COBK, COSS, COSP to ACDOCA