Showing posts with label ABAP-CDS. Show all posts
Showing posts with label ABAP-CDS. Show all posts

Monday, 10 June 2024

CDS based Analytical oData for Fiori

During my developments I found that analytical oData services (or maybe to be more precise "analytical entitysets" within oData services) are needed quite often but it's not very well documented what options can be used to create them. In most of the official literature you will find oData generated on top of "analytical query" but this option is not supported in Restful ABAP programming model and makes some stuff (like adding additional entitysets in the same service) difficult.

As a first thing let's explain "analytical oData" on a very simple example and probably most common scenario: you have some kind of document item which has for example Supplier, Company Code, Fiscal Year, Amount with Currency code and Quantity with Unit. And you perhaps need to get the "sums" of amounts and quantities on different levels

Wednesday, 25 March 2020

CDS based data extraction – Part II Delta Handling

As promised in part one, let’s have a closer look at the delta handling in CDS based extraction.

In cases, in which big data volumes with a frequent changes are expected, e.g. transaction data like sales orders or similar, the application needs to provide delta records. In most of the cases daily (nightly) full uploads are not what you want, as time windows for data extractions are limited. Extraction of transaction data should always be delta enabled as this allows a seamless loading and reporting scenario.

Friday, 12 April 2019

Implementing Time Buckets in SAP ABAP CDS Views

Introduction


When reporting on large size financial, CO-PA or other applications’ dataset, it is often required to aggregate information by time intervals further called time buckets and compare revenues and expenses in two or more time buckets; e.g., Year 2016 vs Year 2015, March 2019 vs March 2018, … etc.

Friday, 28 September 2018

Date Function for dynamic date filtering in Fiori apps

Date Function for Fiori Smart Business app


By using Data Function, it is possible to filter date dynamically in Fiori Smart Business Apps. It is important especially for Smart Business KPI tiles as they don’t   have value prompt screens associated with them. The purpose of this blog is to explain how Date Functions work and how they can be created.

Monday, 3 September 2018

Sample: Custom CDS View using predefined Virtual Data Model and Extend View in S/4HANA

Purpose


This blog intends to encourage you to enjoy high productivity of custom object development by using predefined Virtual Data Model (VDM) in S/4HANA by providing the sample of Custom CDS Views based on predefined VDM enhanced with Extend View. By using predefined VDM, you may not have to create custom CDS Views for all entities. It is always the case that predefined content is totally reusable but it is necessary to add some fields, which is possible with Extend View.

Wednesday, 22 August 2018

Cardinality of Association in CDS View

Purpose


This blog explains how the Cardinality of Association in ABAP CDS View works.

Association is used to link a view (or table) to the source view (or table) in CDS View. In Association, Cardinality is defined. Cardinality is the relationship between the source and associated view in the form of [ min .. max ] (only the target cardinality is stated). When Sales Order is the source and Sales Organization is the target, the cardinality is [0..1]. This blog explains how the internal behavior is changed by the setting of Cardinality in Association.

Wednesday, 15 August 2018

Create a Self-Service BI application powered by SAP Lumira and ABAP CDS views

SAP BusinessObject Lumira (a.k.a. Lumira) is a business intelligence tool focused on analytics and data visualisation, it provides the ability for business analysts to alter data structures and the correlation in the way they need without help of a professional designer or IT specialist.

Wednesday, 30 May 2018

ABAP CDS Consumption View Features Ultimate Test: Part 4

In first part, second part and third part of my blog I put ABAP CDS Consumption View to test and fulfilled some of most typical BW Query requirements. In fourth part of my blog I will challenge ABAP CDS Consumption View again. This time demonstrating percentage share calculation (similar to BW Query %CT function) and filtering key figures structure.

Monday, 30 April 2018

How to use BW Infoobject hierarchy in ABAP CDS views

Introduction


◈ Hierarchies could be loaded or maintained manually in BW embedded in S/4HANA system.

◈ Considered approach is particularly relevant in case in S/4HANA there is embedded planning solution and you need to reuse existing hierarchy in analytical reports based on ABAP CDS views.

Thursday, 26 April 2018

ABAP CDS Consumption View Features Ultimate Test: Part 3

In first part and second part of my blog I put ABAP CDS Consumption View to test and fulfilled some of most typical BW Query requirements. In third part of my blog I will challenge ABAP CDS Consumption View one more time. This time demonstrating time dependent dimensions / hierarchies and language dependent texts.

Sunday, 22 April 2018

ABAP CDS Consumption View Features Ultimate Test: Part 2

In first part of my blog I put ABAP CDS Consumption View to test and fulfilled some of most typical BW Query requirements. In second part of my blog I will challenge ABAP CDS Consumption View even more. This time dynamically setting variable values (similar to BW OLAP Variable user-exit functionality).

Friday, 20 April 2018

ABAP CDS Consumption View Features Ultimate Test: Part 1

ABAP CDS Consumption Views are exposed as BW Queries and can be consumed by S/4 HANA Query Browser and BI Clients like Analysis for Office and Design Studio. With my BW background I was curious to put ABAP CDS Consumption Views to test and fulfill some of the typical BW Query requirements like:

Friday, 27 October 2017

How fast is ABAP Core Data Service(CDS)?

How fast is ABAP Core Data Service (CDS)?  This is one of the frequent question raised by technical consultants after any ABAP CDS sessions. We can demonstrate speed of ABAP CDS through below simple approach, I have written same requirement in two different methodologies. Business requirement is to obtain the material number from MARA table and material description from MAKT table. Material number in final result should be without preceding zero’s.

Thursday, 12 October 2017

WebUI meets ABAP CDS

Introduction


ABAP CDS views allow us to build very nice and structured applications for any solution or UI.

This blog is about how to build a very nice, simple and really fast WebUI application for really crazy data model and volumes, by just using ABAP CDS.

Wednesday, 22 February 2017

How to build a Custom Hierarchy in ABAP CDS views

I was interested in standard analytics capabilities of HCM in S/4HANA (1511) and Orgunit Hierarchy realization in ABAP CDS views.

I. Find a standard HR hierarchy

I started with Query Browser Fiori App and wanted to find standard analytical queries by HCM components like HR-PA, HR-PD, HR-PT, HR-PY etc. But there was not one unfortunately.

After this I went to ABAP dictionary to find where main HR tables, like HRP1000, HRP1001, PA0001 are used. It is possible to find DDL Sources.

Saturday, 3 December 2016

ABAP on HANA – Steps to call a CDS view from another CDS View

Core Data Services (CDS) :


CDS is an infrastructure layer for defining semantically rich data models, which are represented as CDS views.

A CDS view is used to define the structure of an SQL view and represents a projection onto one or several ABAP Dictionary tables or ABAP Dictionary views.

This blog shows how to call a CDS view from another CDS view.

Monday, 21 November 2016

Create Fiori app using CDS with BOPF- For beginners Part 2

This blog is on continuation to  Part 1.

In this part we shall create the BOPF action and display the sale order scenario in the Fiori App using Smart Template.

For the BOPF action, go to BOPF Business Object ZDEMO_I_SALESORDER  from Tcode BOBX. Click on change mode. Under the Node Elements, traverse to node ZDEMO_I_SALESORDER and select Action element. Right Click on Action and Click “Create”.

Tuesday, 15 November 2016

Create Fiori app using CDS with BOPF- For beginners Part 1

Prerequisite:

1) Concepts of Core Data Services(CDS)
2) Basic Understanding of OData service
3) Concepts of BOPF
4) Conceptual knowledge of Fiori(Smart Template)

The Fiori/Ui5 is for the UI part, the CDS is for the data retrieval(code push down) while the BOPF is for handling DB activities.

Saturday, 5 November 2016

CDS ALV report with selection criteria

SAP classes CL_SALV_IDA_* and SAP programs SALV_IDA_* as of 7.5 SP03. With all this functionality provided by SAP, HANA / CDS is powerful development tool saving time and making possible the code pushdown to HANA database.

Create CDS view from ADT using folder Core Data Services, right-click to create New -> DDL Source

CDS ALV report with selection criteria

Thursday, 27 October 2016

ABAP CDS in SAP BW

Introduction

ABAP Core Data Services (CDS) Views were introduced with SAP ABAP 7.40 SP05. CDS allows the creation of rather complex views that by far exceed the capabilities of database views created in SE11. Besides their role in the ABAP Programming Language, CDS Views are the technology behind the virtual data model on top of the SAP S/4HANA application tables which, e.g. is used in SAP S/4HANA Analytics.

This aspect – the role of CDS in SAP S/4HANA Analytics – frequently brings up the question whether or how CDS might be used in the context of SAP BW powered by SAP HANA or SAP BW/4HANA.