P_ExternalTaxAggAmtWithBase
Aggregation of Amount with Tax Base
P_ExternalTaxAggAmtWithBase is a Composite CDS View that provides data about "Aggregation of Amount with Tax Base" in SAP S/4HANA. It reads from 1 data source (P_EXTERNALTAX_AGGITEMANDSTATE) and exposes 31 fields with key fields US_TaxPartnerTaxDocument, US_TaxPartnerTaxDocumentItem. Part of development package ODATA_TAX_DOCUMENT_DISPLAY.
Data Sources (1)
| Source | Alias | Join Type |
|---|---|---|
| P_EXTERNALTAX_AGGITEMANDSTATE | _Amt | from |
Annotations (7)
| Name | Value | Level | Field |
|---|---|---|---|
| AbapCatalog.sqlViewName | PAGGAMTWITHBASE | view | |
| AbapCatalog.compiler.compareFilter | true | view | |
| AbapCatalog.preserveKey | true | view | |
| AccessControl.authorizationCheck | #CHECK | view | |
| ClientHandling.algorithm | #SESSION_VARIABLE | view | |
| VDM.private | true | view | |
| VDM.viewType | #COMPOSITE | view |
Fields (31)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | US_TaxPartnerTaxDocument | P_EXTERNALTAX_AGGITEMANDSTATE | docnr | Well doc.no. |
| KEY | US_TaxPartnerTaxDocumentItem | P_EXTERNALTAX_AGGITEMANDSTATE | itemnr | tax item number |
| TaxState | P_EXTERNALTAX_AGGITEMANDSTATE | tax_state | Tax State | |
| BillToParty | _TaxDocItem | BillToParty | Inv. Recipient | |
| CostCenter | _TaxDocItem | CostCenter | Cost Center | |
| DebitCreditCode | _TaxDocItem | DebitCreditCode | Single-Character Flag | |
| DocumentDate | _TaxDocItem | DocumentDate | Journal Entry Date | |
| FreightAmount | _TaxDocItem | FreightAmount | ||
| MainItemPricingRefMaterial | _TaxDocItem | MainItemPricingRefMaterial | ||
| MaterialGroup | _TaxDocItem | MaterialGroup | Product Group | |
| PointOfOrderAcceptanceTxJx | _TaxDocItem | PointOfOrderAcceptanceTxJx | ||
| PointOfOrderOriginTxJx | _TaxDocItem | PointOfOrderOriginTxJx | ||
| PurchasingDocument | _TaxDocItem | PurchasingDocument | Purchasing Document | |
| QuantityInBaseUnit | _TaxDocItem | QuantityInBaseUnit | Quantity | |
| SalesMeasureUnit | _TaxDocItem | SalesMeasureUnit | Sales unit | |
| SDDocument | _TaxDocItem | SDDocument | SD Document | |
| SDDocumentCategory | _TaxDocItem | SDDocumentCategory | Document Cat. | |
| ServicesRenderedDate | _TaxDocItem | ServicesRenderedDate | Services Rendered Date | |
| ShipFromAddressTaxJurisdiction | _TaxDocItem | ShipFromAddressTaxJurisdiction | ||
| ShipToParty | _TaxDocItem | ShipToParty | Ship-To Party (obsolete) | |
| ShipToAddressTaxJurisdiction | _TaxDocItem | ShipToAddressTaxJurisdiction | ||
| SoldToParty | _TaxDocItem | SoldToParty | Sold-to Party | |
| TaxCalculationDate | _TaxDocItem | TaxCalculationDate | ||
| TaxCode | _TaxDocItem | TaxCode | Tax Code | |
| TaxDepartureCountry | _TaxDocItem | TaxDepartureCountry | Tx Dep Ctry/Reg | |
| US_TaxProduct | _TaxDocItem | US_TaxProduct | ||
| TaxType | _TaxDocItem | TaxType | Tax Type | |
| UnitedStatesTaxCategory | _TaxDocItem | UnitedStatesTaxCategory | ||
| US_TaxPartnerReceivedTaxDate | _TaxDocItem | US_TaxPartnerReceivedTaxDate | ||
| GLTaxAmountOnDoc | _Doc | total_gl_taxamount | ||
| TaxAmountOnDoc | _Doc | total_taxamount_indc |
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_ExternalTaxAggAmtWithBase.
-- 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: PAGGAMTWITHBASE
CREATE VIEW P_ExternalTaxAggAmtWithBase AS
SELECT
_Amt.docnr AS US_TaxPartnerTaxDocument,
_Amt.itemnr AS US_TaxPartnerTaxDocumentItem,
_Amt.tax_state AS TaxState,
_TaxDocItem.BillToParty AS BillToParty,
_TaxDocItem.CostCenter AS CostCenter,
_TaxDocItem.DebitCreditCode AS DebitCreditCode,
_TaxDocItem.DocumentDate AS DocumentDate,
_TaxDocItem.FreightAmount AS FreightAmount,
_TaxDocItem.MainItemPricingRefMaterial AS MainItemPricingRefMaterial,
_TaxDocItem.MaterialGroup AS MaterialGroup,
_TaxDocItem.PointOfOrderAcceptanceTxJx AS PointOfOrderAcceptanceTxJx,
_TaxDocItem.PointOfOrderOriginTxJx AS PointOfOrderOriginTxJx,
_TaxDocItem.PurchasingDocument AS PurchasingDocument,
_TaxDocItem.QuantityInBaseUnit AS QuantityInBaseUnit,
_TaxDocItem.SalesMeasureUnit AS SalesMeasureUnit,
_TaxDocItem.SDDocument AS SDDocument,
_TaxDocItem.SDDocumentCategory AS SDDocumentCategory,
_TaxDocItem.ServicesRenderedDate AS ServicesRenderedDate,
_TaxDocItem.ShipFromAddressTaxJurisdiction AS ShipFromAddressTaxJurisdiction,
_TaxDocItem.ShipToParty AS ShipToParty,
_TaxDocItem.ShipToAddressTaxJurisdiction AS ShipToAddressTaxJurisdiction,
_TaxDocItem.SoldToParty AS SoldToParty,
_TaxDocItem.TaxCalculationDate AS TaxCalculationDate,
_TaxDocItem.TaxCode AS TaxCode,
_TaxDocItem.TaxDepartureCountry AS TaxDepartureCountry,
_TaxDocItem.US_TaxProduct AS US_TaxProduct,
_TaxDocItem.TaxType AS TaxType,
_TaxDocItem.UnitedStatesTaxCategory AS UnitedStatesTaxCategory,
_TaxDocItem.US_TaxPartnerReceivedTaxDate AS US_TaxPartnerReceivedTaxDate,
_Doc.total_gl_taxamount AS GLTaxAmountOnDoc,
_Doc.total_taxamount_indc AS TaxAmountOnDoc
FROM P_EXTERNALTAX_AGGITEMANDSTATE AS _Amt
;
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