P_SK_CompanyCodeTaxAbroad
P_SK_CompanyCodeTaxAbroad is a Consumption CDS View in SAP S/4HANA. It reads from 3 data sources (I_CompanyCode, I_CompanyCode, P_SK_TaxAbroadRegistration) and exposes 33 fields with key fields CompanyCode, ReportingCountry, ReportingCountry. It has 1 association to related views.
Data Sources (3)
| Source | Alias | Join Type |
|---|---|---|
| I_CompanyCode | CompanyCode | from |
| I_CompanyCode | CompanyCode | inner |
| P_SK_TaxAbroadRegistration | TaxAbroad | union |
Associations (1)
| Cardinality | Target | Alias | Condition |
|---|---|---|---|
| [0..1] | I_Address_2 | _Address | _Address.AddressID = $projection.AddressID and _Address.AddressPersonID is initial and _Address.AddressRepresentationCode is initial |
Annotations (4)
| Name | Value | Level | Field |
|---|---|---|---|
| AccessControl.authorizationCheck | #NOT_REQUIRED | view | |
| Metadata.ignorePropagatedAnnotations | true | view | |
| VDM.private | true | view | |
| VDM.viewType | #CONSUMPTION | view |
Fields (33)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | CompanyCode | I_CompanyCode | CompanyCode | Receiver Company Code |
| KEY | ReportingCountry | I_CompanyCode | Country | Venue: Ctry/Reg |
| CompanyCodeCountry | I_CompanyCode | Country | Venue: Ctry/Reg | |
| OrganizationName1 | _Address | OrganizationName1 | Name | |
| OrganizationName2 | _Address | OrganizationName2 | Name 2 | |
| OrganizationName3 | _Address | OrganizationName3 | Name 3 | |
| OrganizationName4 | _Address | OrganizationName4 | Name 4 | |
| StreetName | _Address | StreetName | Text | |
| HouseNumber | _Address | HouseNumber | House Number | |
| PostalCode | _Address | PostalCode | Postal Code | |
| CityName | _Address | CityName | Name | |
| Country | _Address | Country | Venue: Ctry/Reg | |
| EmailAddress | ||||
| VATRegistration | I_CompanyCode | VATRegistration | VAT Registration No. | |
| VATRegistrationCountry | ||||
| VATRegistrationWithoutCountry | ||||
| CompanyCode | Receiver Company Code | |||
| KEY | ReportingCountry | P_SK_TaxAbroadRegistration | Country | Venue: Ctry/Reg |
| CompanyCodeCountry | I_CompanyCode | Country | Venue: Ctry/Reg | |
| OrganizationName1 | Name | |||
| OrganizationName2 | Name 2 | |||
| OrganizationName3 | Name 3 | |||
| OrganizationName4 | Name 4 | |||
| StreetName | Text | |||
| HouseNumber | House Number | |||
| PostalCode | Postal Code | |||
| CityName | Name | |||
| Country | Venue: Ctry/Reg | |||
| EmailAddress | ||||
| VATRegistration | P_SK_TaxAbroadRegistration | VATRegistration | VAT Registration No. | |
| VATRegistrationCountry | ||||
| VATRegistrationWithoutCountry | ||||
| AddressID | P_SK_TaxAbroadRegistration | AddressID | Ship-to address |
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_SK_CompanyCodeTaxAbroad.
-- 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.
CREATE VIEW P_SK_CompanyCodeTaxAbroad AS
SELECT
CompanyCode.CompanyCode AS CompanyCode,
CompanyCode.Country AS ReportingCountry,
CompanyCode.Country AS CompanyCodeCountry,
_Address.OrganizationName1 AS OrganizationName1,
_Address.OrganizationName2 AS OrganizationName2,
_Address.OrganizationName3 AS OrganizationName3,
_Address.OrganizationName4 AS OrganizationName4,
_Address.StreetName AS StreetName,
_Address.HouseNumber AS HouseNumber,
_Address.PostalCode AS PostalCode,
_Address.CityName AS CityName,
_Address.Country AS Country,
_Address._CurrentDfltEmailAddress.EmailAddress AS EmailAddress,
CompanyCode.VATRegistration AS VATRegistration,
left(CompanyCode.VATRegistration, 2) AS VATRegistrationCountry,
substring(CompanyCode.VATRegistration, 3, 18) AS VATRegistrationWithoutCountry,
TaxAbroad.AddressID AS AddressID
FROM I_CompanyCode AS CompanyCode
INNER JOIN I_CompanyCode AS CompanyCode ON /* join condition not captured in parsed metadata */
LEFT OUTER JOIN I_Address_2 AS _Address ON _Address.AddressID = AddressID AND _Address.AddressPersonID is initial AND _Address.AddressRepresentationCode is initial -- association [0..1]
-- UNION with additional select branch(es): P_SK_TaxAbroadRegistration
;
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