Demo_Chess_V_Stage2
Helper View to generate allowed movements
Demo_Chess_V_Stage2 is a CDS View that provides data about "Helper View to generate allowed movements" in SAP S/4HANA. It reads from 2 data sources (Demo_Chess_V_Stage1, Demo_Chess_V_Pos_Cds) and exposes 20 fields with key fields gameuuid, movecnt, color, chessman, from_x. Part of development package SABAP_DEMOS_SQL_CHESS.
Data Sources (2)
| Source | Alias | Join Type |
|---|---|---|
| Demo_Chess_V_Stage1 | moves | from |
| Demo_Chess_V_Pos_Cds | position | inner |
Annotations (4)
| Name | Value | Level | Field |
|---|---|---|---|
| AbapCatalog.sqlViewName | DEMO_CHESS_SST2 | view | |
| AbapCatalog.compiler.compareFilter | true | view | |
| AccessControl.authorizationCheck | #NOT_ALLOWED | view | |
| EndUserText.label | Helper View to generate allowed movements | view |
Fields (20)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | gameuuid | Demo_Chess_V_Stage1 | gameuuid | UUID |
| KEY | movecnt | Demo_Chess_V_Stage1 | movecnt | Halbzugnummer |
| KEY | color | Demo_Chess_V_Stage1 | color | Level Color |
| KEY | chessman | Demo_Chess_V_Stage1 | chessman | Schachfigur |
| KEY | from_x | Demo_Chess_V_Stage1 | from_x | X-Position |
| KEY | from_y | Demo_Chess_V_Stage1 | from_y | Y-Position |
| KEY | to_x | Demo_Chess_V_Stage1 | to_x | X-Position |
| KEY | to_y | Demo_Chess_V_Stage1 | to_y | Y-Position |
| other_color | Demo_Chess_V_Pos_Cds | color | Level Color | |
| other_x | Demo_Chess_V_Pos_Cds | x | X-Position | |
| other_y | Demo_Chess_V_Pos_Cds | y | Y-Position | |
| special_flag | Demo_Chess_V_Stage1 | special_flag | Special Flag | |
| color_dep | Demo_Chess_V_Stage1 | color_dep | Color | |
| chessman_dep | Demo_Chess_V_Stage1 | chessman_dep | Schachfigur | |
| from_x_dep | Demo_Chess_V_Stage1 | from_x_dep | X-Position | |
| from_y_dep | Demo_Chess_V_Stage1 | from_y_dep | Y-Position | |
| to_x_dep | Demo_Chess_V_Stage1 | to_x_dep | X-Position | |
| to_y_dep | Demo_Chess_V_Stage1 | to_y_dep | Y-Position | |
| first_slope | ||||
| second_slope |
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 Demo_Chess_V_Stage2.
-- 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: DEMO_CHESS_SST2
CREATE VIEW Demo_Chess_V_Stage2 AS
SELECT
moves.gameuuid AS gameuuid,
moves.movecnt AS movecnt,
moves.color AS color,
moves.chessman AS chessman,
moves.from_x AS from_x,
moves.from_y AS from_y,
moves.to_x AS to_x,
moves.to_y AS to_y,
position.color AS other_color,
position.x AS other_x,
position.y AS other_y,
moves.special_flag AS special_flag,
moves.color_dep AS color_dep,
moves.chessman_dep AS chessman_dep,
moves.from_x_dep AS from_x_dep,
moves.from_y_dep AS from_y_dep,
moves.to_x_dep AS to_x_dep,
moves.to_y_dep AS to_y_dep,
( moves.to_x - moves.from_x ) * ( position.y - moves.from_y ) AS first_slope,
( position.x - moves.from_x ) * ( moves.to_y - moves.from_y ) AS second_slope
FROM Demo_Chess_V_Stage1 AS moves
INNER JOIN Demo_Chess_V_Pos_Cds AS position ON /* join condition not captured in parsed metadata */
;
Learn More
- CDS View Annotations — A Complete Guide
- What Is a CDS View in SAP S/4HANA?
- Types of CDS Views: Basic, Composite, Consumption, and Transactional
- SAP Tables vs CDS Views — Key Differences
- Understanding Data Lineage in SAP S/4HANA
- VDM (Virtual Data Model) in SAP S/4HANA Explained
- 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