Abap On Hana
Abap On Hana
Abap On Hana
This page is a hand written note from (and probably to) an SAP HANA novice who is
trying to remember and understand the new terminologies.
Please check SAP ABAP for HANA Tutorial for multiple articles in detail on ABAP for
SAP HANA.
Wiki says: SAP HANA, short for �High Performance Analytic Appliance� is an in-
memory, column-oriented, relational database management system developed and
marketed by SAP SE. HANA�s architecture is designed to handle both high transaction
rates and complex query processing on the same platform.
Multicore architecture for CPUs and 64-bit address space innovation in hardware
enabled SAP to design SAP HANA. Similarly, columnar data storage, improved data
compression algorithms and insert only approach innovation in software have
contributed to the SAP HANA evolution.
Also Read: Create your first program in SAP HANA Studio (ABAP on SAP HANA Part I).
Good thing is all databases certified by SAP support the recent Open SQL
enhancements (eg CDS). So if we really would like or really would have to consume
native HANA artifacts or features that are not accessible with Open SQL or with
CDS, we have to dig deeper and you have to consume them natively. The other good
thing is if you need to make change in existing Open SQL statements to new Open SQL
syntax and there are other Open SQL statements in your object, you need not change
all. They are still valid.
SAP NetWeaver 7.4, generally available since May 2013, is the version that is
currently fully optimized for SAP HANA. It also facilitates the development of
modern browser-based and mobile applications because of its integrated UI
development toolkit for HTML5 (SAP�s adaptation of the HTML5 standard, known as
SAPUI5) and SAP NetWeaver Gateway capabilities.
At the core of SAP HANA is the high-performance, in-memory SAP HANA database. It
can manage structured and unstructured data, and supports both transactional and
analytical use cases. As a traditional relational database, the SAP HANA database
can function either as the data provider for classic transactional applications
(OLTP) and/or as a data source for analytical requests (OLAP).
SAP HANA provides standard database interfaces such as JDBC and ODBC and supports
standard SQL with SAP HANA-specific extensions. In short, SAP HANA is an RDBMS
offering SQL interface and transactional isolation.
The latest release of SAP NetWeaver is optimized for SAP HANA and adds new
capabilities to the developer�s workbench for cloud, mobile and social networking.
Columnar storage, in many cases, eliminates the need for additional index
structures. Storing data in columns is functionally similar to having a built-in
index for each column. The column scanning speed of the in-memory column store and
the compression mechanisms � especially dictionary compression � allow read
operations with very high performance. In many cases, it is not required to have
additional indexes. Eliminating additional indexes reduces complexity and
eliminates the effort of defining and maintaining metadata.
SAP HANA dictionary compression is realized for column store tables by sorting
dictionary with the distinct values of the column and each column uses an array of
integer values that represent the positions of the actual values in the dictionary.
When the table contains a huge amount of data that is frequently searched or
aggregated and when the table contains many columns and typical queries access only
a few of them then column store for table is recommended.
ABAP in Eclipse:
The ABAP Development Tools for SAP NetWeaver tie in perfectly with SAP HANA Studio
and SAP�s in-memory technology by allowing highly productive application
development on top of SAP HANA. The ABAP Development Tools significantly increases
ABAP developer productivity through rich Eclipse user experience and flexibility,
new capabilities for sophisticated source code implementation, task-oriented and
test-driven business development. The ABAP Development Tools enables cross-platform
application development by integrating ABAP and non-ABAP development tools into one
Eclipse-based IDE. Built-in extensibility of the IDE through the established
Eclipse plug-in technology enables you to benefit from the huge Eclipse ecosystem,
develop on open platform and integrate new custom ABAP and non-ABAP tools. ABAP
Project in ABAP Perspective in ADT for SAP NetWeaver serves as a central interface
for communication between the Eclipse based development environment and the ABAP
back end system.
As a rule, an ABAP program containing database-specific SQL statements will not run
under different database systems. If your program will be used on more than one
database platform, only use Open SQL statements.
Please note, all ABAP custom code would not show drastic performance improvement
automatically. In order to take maximum advantage of SAP HANA, our custom code
should be in compliance with the enhanced SQL performance guidelines.
The SQL Monitor (SQLM) can be used to capture the SQL profile of the ABAP system.
SQL Monitor data can be exchanged between two systems by creating a snapshot of the
SQL Monitor data, exporting it to the file system, and then importing it to the
target system. SQL profile of the business processes in the production system can
be captured because of the fact that SQL Monitor introduces only a minimal
performance overhead.
SQL Performance Tuning Worklist (SWLT) allows correlating the results of an ABAP
source code analysis with SQL runtime data. The report gives a list which might
have potential issues. We should start investigating the ones which are at the top.
We need to set a goal as to how much we want to optimize. Work on those set and
check if the corrections/optimizations meet our self-defined or business defined
requirements.
SAP List Viewer with Integrated Data Access (ALV with IDA) is based on the
principle to select only the data to be displayed from the database and perform
calculations, aggregations, and grouping on the database layer.
Core Data Services (CDS) views and AMDP (ABAP Managed Database Procedures) ABAP
artifacts can be created and maintained via ABAP Development Tools for SAP
NetWeaver.
Now let us look at the formal definition and explanations. �Core Data Services,�
are a higher-order SQL that relieves application developers from low-level SQL
coding for adding referential navigation by generating the required code
automatically, and also forms the basis for unified data models in the SAP HANA
context. The intention is for SAP HANA to be able to consume various data sources
on the same semantic level regardless of whether they are delivered by an ABAP
program or SAP BusinessObjects model. Core data services are included as part of
SAP HANA extended application services, an application server that is shipped with
SAP NetWeaver 7.4 SPS 05 and SAP HANA as of SPS 06.
�Map to Data source� option in SAP NetWeaver Gateway Service Builder (transaction
SEGW) can be used to implement the consumption of a Core Data Services view. The
DDL source (DDLS) in which the CDS view is defined is included in a transport
request when we transport a Core Data Services (CDS) view. CDS views can also be
extended using EXTEND VIEW statement programatically.
Associations in a Core Data Services (CDS) view can be consumed in the FROM clause;
in the WHERE and HAVING clauses and in the projection list. The main purpose of
associations in Core Data Services is to define relationships between entities.
Dictionary tables, CDS views and Dictionary views can be used as a data source in a
Core Data Services (CDS) view. In simpl words, ABAP Dictionary tables, CDS views,
Dictionary views can be queried in the Open SQL SELECT statement.
While consuming the Association in the CDS using a path expression, a JOIN is
constituted in the underlying database.
Benefits of replacing JOIN statement with Association in CDS view is that it can be
consumed using simple path expression and ON conditions for association are
generated automatically and association can also be exposed themselves.
The main advantage of using Core Data Services (CDS) in SAP NetWeaver Application
Server ABAP is, we can define complex data models that can be consumed in a simple
Open SQL SELECT statement and we can use the extended view-definition functionality
to push down code to the database layer. It is important to note that scalar input
parameters are database dependent. So, if we plan to consume a CDS view using FROM
clause of Open SQL query with scalar input then we need to keep in mind that the
query cannot be executed on all SAP-certified databases for the database dependent
scalar inputs.
Check how we can create AMDP Class/Method and consume it in ABAP Program.
In direct words, AMDP is nothing else but a container of methods. And the procedure
itself is deployed and executed on the HANA database. ABAP Managed Database
Procedure follows the Top-Down approach. In order to implement an ABAP Managed
Database Procedure method we need to implement (mandatory) the class interface
IF_AMDP_MARKER_HDB. ABAP language elements LANGUAGE db_lang (db_lang = SQLSCRIPT�),
FOR db (db = HDB�) and BY DATABASE PROCEDURE are mandatory for the implementation
of a method as an ABAP Managed Database Procedure. AMDP can also improve the
performance of data transformation in the Extract, Transform and Load (ETL) process
in BW. We can consume an ABAP Managed Database Procedure in your ABAP coding by
calling the corresponding ABAP class method. Source code management using the ABAP
transportation infrastructure, Static syntax checks of database-specific coding and
Database independency are the advantages of using AMDP.
Please stay tuned for more on HANA. I would show you how you can get free access to
SAP HANA Cloud Platform. Yes, it is free!! I have already logged into it and making
my hands dirty on it. I am playing it using Eclipse Studio. I will show in details
how you can easily set it up.
If you want to get practical issues and resolutions straight to your inbox, please
SUBSCRIBE. We respect your privacy and take protecting it seriously.
If you liked this post, please hit the share button at the left side of your
screen.
WhatsApp had the limitation of 256 members per group and we were finding a hard
time syncing and maintaining information in multiple WhatsApp group. Therefore we
have moved to Telegram as it can accommodate more than 10,000 users. Please join.
ABAP
Push Notification in SAP � ABAP Push Channel, ABAP Messaging Channel in SAPUI5 � a
Real Time Interaction
SAP Fiori
Trick to Send QR code or Barcode Data Remotely from Android to PC for SAPUI5 App
9 COMMENTS
Angesh September 20, 2017 at 2:23 am
Hi SAPYard,
Thanks for your wonderful blog, Now my question is how can I debug CDS view on Hana
Studio.
Thanks in advance,
Angesh
Regards,
Team SAPYard..
Regards,
Raju.
Thanks
Regards,
Raju.
Regards,
Team SAPYard.
Regards
OData and SAP Netweaver Gateway. Part VIII. SAP�s Love for OData...
April 11, 2017
Free SAP Video Training
4 Smart Steps to Avoid Junk Characters using SAP Language Translation...
October 23, 2018
www.sapyard.com
WSDL file in SAP � Part I
October 21, 2008
Load more
SAP is Exciting
Report
Is data element BOOLE_D and CHAR1 same in SAP Selection Screen?
se43
Enhancement
Calling SAP Menu Areas From Program
IDoc
You�hv got an IDoc !!
How to Consume OData Service
Fiori
SAPUI5 for ABAPers � Consuming OData Service from SAPUI5 Application �...
Recent Comments
SMAALI Achraf on Some Common Nuisances of ABAP 7.40
Raj on What is INSERT Only Approach in HANA?
akashwork31 on How to Merge PDF Files using SAP.. absolutely Free?
Stallone on How to Merge PDF Files using SAP.. absolutely Free?
prasanth on 14. ALPHA Conversion
FOLLOW US ON INSTAGRAM @SAPYARD
EDITOR PICKS
Cardova API in SAP
How to send e-mail in SAPUI5 Hybrid App?
January 15, 2019
SAP Book Review
Book Review � SAP: An Introduction
January 12, 2019
Please help keep SAPYard free, for anyone anywhere forever. Support & Donate.
Forums All SAP Tutorials Tutorials on SAP ABAP on HANA Write & Earn SAP Interview
Q&A SAPYard YouTube Channel Shop & Support Video Tutorials Donate
� 2014-2018. SAP and other SAP products and services mentioned herein as well as
their respective logos are trademarks or registered trademarks of SAP SE (or an SAP
affiliate company) in Germany and other countries. All other product and service
names mentioned are the trademarks of their respective companies. SAPYard is not
affiliated with SAP SE or any of the SAP SE group of companies.