I_TownshipCode

DDL: I_TOWNSHIPCODE SQL: ITOWNSHIPCODE Type: view BASIC

Township Code

I_TownshipCode is a Basic CDS View that provides data about "Township Code" in SAP S/4HANA. It reads from 1 data source (adrtownship) and exposes 8 fields with key fields Country, Region, County, Township. It has 4 associations to related views.

Data Sources (1)

SourceAliasJoin Type
adrtownship adrtownship from

Associations (4)

CardinalityTargetAliasCondition
[0..*] I_TownshipCodeText _Text $projection.Country = _Text.Country and $projection.Region = _Text.Region and $projection.County = _Text.County and $projection.Township = _Text.Township
[1..1] I_CountyCode _County $projection.Country = _County.Country and $projection.Region = _County.Region and $projection.County = _County.County
[1..1] I_Region _Region $projection.Region = _Region.Region and $projection.Country = _Region.Country
[1..1] I_Country _Country $projection.Country = _Country.Country

Annotations (11)

NameValueLevelField
AbapCatalog.sqlViewName ITOWNSHIPCODE view
AbapCatalog.compiler.compareFilter true view
AbapCatalog.preserveKey true view
AccessControl.authorizationCheck #NOT_REQUIRED view
EndUserText.label Township Code view
ClientHandling.algorithm #SESSION_VARIABLE view
VDM.viewType #BASIC view
ObjectModel.representativeKey Township view
ObjectModel.usageType.serviceQuality #A view
ObjectModel.usageType.sizeCategory #M view
ObjectModel.usageType.dataClass #CUSTOMIZING view

Fields (8)

KeyFieldSource TableSource FieldDescription
KEY Country country Venue: Ctry/Reg
KEY Region region Venue Region
KEY County county_code County code
KEY Township township_code Township code
_Text _Text
_County _County
_Region _Region
_Country _Country

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 I_TownshipCode.
-- 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: ITOWNSHIPCODE

CREATE VIEW I_TownshipCode AS
SELECT
  Country,
  Region,
  county_code AS County,
  township_code AS Township
FROM adrtownship
LEFT OUTER JOIN I_TownshipCodeText AS _Text ON Country = _Text.Country AND Region = _Text.Region AND County = _Text.County AND Township = _Text.Township  -- association [0..*]
LEFT OUTER JOIN I_CountyCode AS _County ON Country = _County.Country AND Region = _County.Region AND County = _County.County  -- association [1..1]
LEFT OUTER JOIN I_Region AS _Region ON Region = _Region.Region AND Country = _Region.Country  -- association [1..1]
LEFT OUTER JOIN I_Country AS _Country ON Country = _Country.Country  -- association [1..1]
;