Basic CDS View Creation

Open HANA Studio. Goto ABAP perspective. Open the project, Navigate to the package. Right click on the package & select New->Other ABAP Repository Object.

Expand Code Data Services & select DDL Source and finally select NEXT button.

Provide CDS view name & description. Select FINISH button.

The view editor opens up. Here we have to provide the details.


Provide SQL VIEW NAME, provide a meaningful end user text label, provide view type as BASIC.

On the define view statement, provide the select form as “SFLIGHT”, mention the field names marking key fields. Activate and execute the view.


@AbapCatalog.sqlViewName: ‘ZSFLIGHTVIEW’
@AbapCatalog.compiler.compareFilter: true
@AccessControl.authorizationCheck: #NOT_REQUIRED
@EndUserText.label: ‘Flight Information’
@VDM.viewType: #BASIC
define view Zflight_View as select from sflight{
key sflight.carrid as AirlineCode,
key sflight.connid as ConnectionNumber,
key sflight.fldate as FlightDate,
sflight.price as Airfare,
sflight.currency as FareCurrency,
sflight.planetype as PlaneCategory,
sflight.seatsmax as MaxAvailableSeats,
sflight.seatsocc as OccupiedSeats
}

  


Here is the CDS view output.

Once the DATA Definition is activated,  ddl sql view is created.

ABAP CDS ON HANA-(1)CDSビュー作成的更多相关文章

  1. ABAP on HANA之CDS Association和Path Expression

    本文阐述了ABAP CDS association的概念,并且展示了在CDS视图中和SQL语句中写路径表达式(Path Expression)代码的方法.我也会解释如何在CDS asociation中 ...

  2. 如何在SAP云平台ABAP编程环境里把CDS view暴露成OData服务

    Jerry 2016年在学习SAP CDS view时,曾经写过一个CDS view的自学系列,其中有一篇提到了一个很方便的注解: @OData.publish: true 加上这个注解的CDS vi ...

  3. HANA CDS与ABAP CDS

    如果你在网络或者SCN上面搜索CDS,即SAP的Core Data Services,你会很容易地找到类似“Core Data Services(CDS)是一个在SAP HANA中用于定义和消费富语义 ...

  4. 教程:基于访问控制的ABAP CDS视图权限

    Hi! 对每一个CDS视图,我们都可以通过DCL(Data Control Language)定义访问控制.在这篇文章中,我会介绍ABAP CDS视图中非常重要的一面:权限管理. 本文的阐述基于我正在 ...

  5. ABAP CDS-介绍(ABAP CDS视图)

    前言 文章翻译自Tushar Sharma的文章,转载请注明原作者和译者! 在SAP发展到SAP HANA版本之后,SAP内部的技术正在快速地变化,SAP开发业务应用程序的方式已经发生了范式转变(根本 ...

  6. ABAP CDS-Part 1(ABAP CDS实体)

    文章翻译自Tushar Sharma的文章,转载请注明原作者和译者! 目录 预备条件 一.概述 二.ABAP CDS实体(CDS Entity) a.定义ABAP CDS Views b.ABAP C ...

  7. CDS测试框架介绍:如何为ABAP CDS Entities写测试

    动机 现在大家都知道单元测试对我们代码的好处.并且我们都承认它是开发过程中不可或缺的一部分.但是在把代码切换到数据库的模式下的时候,我们被粗暴地打回了软件测试的黑暗年代...我们现在面临着逻辑下推到A ...

  8. ABAP CDS 替换对象(Replacement Objects)引起的数据错误

    最近遇到了一个诡异的问题:从CDS视图中取得的数据,和从透明表中取得的数据,会有不同的值.在这里记录下问题的表现和解决方案,以供参考. 系统版本:S/4HANA OP1610 涉及表:MCHB 本文链 ...

  9. ABAP CDS ON HANA-(11)ABAP CDSでの関連付け

    Association in ABAP CDS An association in CDS view joins different data sources. Defining and using ...

  10. ABAP CDS - Syntax

    The syntax of the DDL and of the DCL of the ABAP CDS comprises elements of the general DDL and DCL o ...

随机推荐

  1. rac环境修改除vip外的其他ip地址方法

    官方参考文档(metalink):如何修改集群的公网信息(包括 VIP) (文档 ID 1674442.1) 同事在测试环境测试通过,使用如下方法.如果有疑问,请参照上述文档,写的很详细.1.停止相关 ...

  2. QQ空间那年今日 & 人人过往的今天

    都说天下文章一大抄!就看你会抄不会抄! 过往的今天这个功能很新颖,不过最后还是被企鹅抄走了~该出手时就出手! 自从过往的今天功能低调上线后,断断续续总是有人提到这个功能,有褒有贬: 顶的认为人人让自己 ...

  3. Inner Join, Left Outer Join和Association的区别

    测试用的CDS视图的源代码,第8行用Inner Join连接TJ02T, 后者存放了所有系统状态的ID和描述. Inner Join测试结果:对于那些在TJ02T里没有维护描述信息的状态,它们不会出现 ...

  4. codeforces 609E Minimum spanning tree for each edge

    E. Minimum spanning tree for each edge time limit per test 2 seconds memory limit per test 256 megab ...

  5. hihocoder 后缀自动机四·重复旋律6

    题目 对于\(k\in[1,n]\)求出长度为\(k\)的子串出现次数最多的出现了多少次 我直到现在才理解后缀自动机上的子树和是什么意思 非常显然的一点是 \[endpos(link(u))⊇endp ...

  6. highcharts(前端报表生成)

    前端报表技术:使用 JavaScript 生成漂亮图表 百度 echarts: http://echarts.baidu.com/examples.html Funsioncharts : http: ...

  7. 关于eclipse中引入项目报错或者没有JRE System Library问题(jre报错)或者jre1.7(8)改为jre1.8(7)等问题

    解决方法: 右键项目工程-->>properties->>java bulid path -->>>libraries -->>add libra ...

  8. Graphics Card Notes | 烧卡日记(显卡常识笔记)

    [ a comparison of several popular Graphics cards ]

  9. 【luogu P1343 地震逃生】 题解

    题目链接:https://www.luogu.org/problemnew/show/P1343 菜 #include <queue> #include <cstdio> #i ...

  10. CodeForces - 600B Queries about less or equal elements (二分查找 利用stl)

    传送门: http://codeforces.com/problemset/problem/600/B Queries about less or equal elements time limit ...