Friday 30 October 2020

Display QR Code for GST INDIA E-Invoicing on Script and Smartform

This blog post has been drafted together with my colleague Rabindra Prasad regarding QR code display for GST INDIA E-Invoicing on Script and Smart Forms as many developers are facing problems to display proper QR code.

Please follow below steps to display it as expected.

In most of the cases, existing form will be altered to accommodate the QR code and other IRN details. This blog post is to fulfil the above requirement.

Wednesday 28 October 2020

Mass-activating multiple objects (in background)

1. Introduction

This blog post shows how to mass-activate multiple objects (in the background) and where to find the logs for the activation.

Since SAP decided to discontinue the IS-Media solution, we often have the requirement to add custom fields to MARA or similar tables in the S/4 HANA migration project I currently work on. Unfortunately, the current extension concept does not meet all our requirements and we get the change requests to add new fields or change existing fields only little by little, which means that we have to repeat this step every few weeks.

Tuesday 27 October 2020

Consuming REST APIs with (Cloud) ABAP

API stands for Application Programming Interface, and comprises a set of standards that allow two applications to talk to each other. REST APIs are a certain pattern of building APIs. They are based on the HTTP protocol, sending and receiving JSON or XML data through URIs (uniform resource identifier). JSON-based REST APIs are prevalent. We will also be using such one in this tutorial.

OData, which is very popular in the SAP world, is itself a REST API. There is a lot of information out there on how to provide a REST API from ABAP (i.e., to publish an OData service). But there isn’t much on how to consume an external API in ABAP. And from what little there is, it includes non-whitelisted ABAP APIs, i.e., they cannot be used with Cloud ABAP. So, I decided to write this tutorial on consuming REST APIs using Cloud ABAP.

Monday 26 October 2020

CI/CD Tools for SAP Cloud Platform ABAP Environment

In the on-premise ABAP world, lifecycle and quality processes can be controlled by the ABAP systems themselves. Think of transport routes and jobs to execute different checks. In the SAP Cloud Platform ABAP Environment aka Steampunk, this is no longer possible. Steampunk systems are independent of each other, and source code is “transported” with git-based solutions: gCTS and abapGit. While different systems in one global account are connected to the same repositories (read: “software components”), they do not know of each other. Due to this, the driver of lifecycle and quality processes needs to shift from the ABAP system itself to an external driver – for example: a classic Continuous Integration / Continuous Delivery (CI/CD) server like Jenkins. Of course, the Steampunk systems need to expose the functionality via APIs so that a CI/CD server can control those processes.

Sunday 25 October 2020

$Skiptoken System Query Option In SAP ODATA

In this blog we will learn how to use query option $skiptoken in gateway OData service.

To achieve server-side paging we will use $skiptoken.

Paging

It is the process of restricting the number of entries sent to the application. This also helps to increase the performance if a huge number of entries requested. This is of two types Server-side paging and Client-side paging.

Friday 23 October 2020

Easy Handling of Complex Selection Screen

Introduction

Most of us have faced this problem when designing a selection screen with a lot of fields. For example consider the scenario where you have to design selection screen for an ABAP Report which includes multiple Radio Buttons and accordingly the selection criteria i.e., select option or parameter should be made visible and hidden and also some radio can have authority object attached to it.

So in this blog post you will learn how you can reduce the complexity of Selection Screen Field visiblility inside the statement LOOP AT SCREEN.

Monday 19 October 2020

ABAP Exception Class ZCX_RETURN2 – Raise code templates

This blog post contains code templates for adding ZCX_RETURN2 exception raising code.

Template overview

◉ CREATE_BY_SYSTEM_MESSAGE (without MESSAGE statement)

◉ CREATE_BY_SYSTEM_MESSAGE (with MESSAGE statement for custom message)

◉ CREATE_BY_BAPIRETURN_STRUC

◉ CREATE_BY_BAPIRETURN_TABLE

◉ CREATE_BY_BAPIRET1_TABLE

◉ CREATE_BY_BAPIRET2_STRUC

◉ CREATE_BY_BAPIRET2_TABLE

◉ CREATE_BY_BDC_MESSAGE_TABLE

◉ CREATE_BY_EXCEPTION_OBJECT – catch for example CX_ROOT

Friday 16 October 2020

Feature switch framework proposal explained

In this blog I’ll try to explain my initial thoughts and are hoping for your feedback.

So briefly the intention is to build a feature switch framework that would enable an organisation to quickly turn off new code changes that has been brought in via transports if proven buggy. This buys the organisation time to provide a proper fix. I can vouch for this where i’m at currently as there is a very lengthy governance process.

The other part of it would be to enable new development to be rolled out gradually instead of always a big bang release when the code hits production. This enables you to run beta program and early releases to get the feedback from your end users earlier than otherwise as they can get their hands dirty.

Wednesday 14 October 2020

Custom MetaNet creation using Function Modules – HRFORMS_METADATA

Initial Situation:

Initially our client was using the pay slips designed in Sap Script to display the results in the off-cycle workbench of payroll. However a new requirement was raised, where the client wanted to replace the Sap Script pay slip format (that looks like an sap script) with PDF forms. After much research, I have suggested the solution to be implemented with the use of HRFORMS which allows us to implement the solution by providing an interface that provides the payroll data to design the forms using Adobe forms or Smartforms platforms.

Monday 12 October 2020

Explained : Measuring Code

Premise:

Measuring system for real world objects and code is different. Virtual system measuring metrices evolved over the years. But are they fit for today’s world?

Code measuring systems and metrices rely on quality and syntax of written code.

Friday 9 October 2020

Controlled usage : Not released Functions

Premise:

Usage of standard functions in custom code is not something new, and in my experience standard functions are one of most used artefacts in customer code.

When using standard functions release status is one of the most important topics that come up quite frequently.

At the end of this blog you should be able to identify whether a standard function is ok to use in customer code or not. Also, what can be the implications / risks introduced by using such an object.

Wednesday 7 October 2020

A tale of code

Take a look at this:

Mr. Enfield returned: "But I happen to have noticed his address; 

                      he lives in some square or other".

"And you never asked about the—place with the door?" 

Mr. Enfield's reply was:  "No, sir; 

Tuesday 6 October 2020

How can we create Code Templates in ABAP Editor SE38/SE80? The Google Way

Introduction

If you are an ABAPer you must be using the TAB key in your keyboard a lot to Auto Fill Keyword Commands. Last year Google have taken this TAB Key concept in writing emails which is awesome. This Blog will help in saving Code Templates that you can use in any ABAP Program.

Monday 5 October 2020

Showing an avatar with Initials or Image on the Fiori Element Object Page for a better user experience using RAP

I always felt like something is missing in all the FE Object Page apps when there is no avatar displayed in the header. I mean, just check the below image, and see how beautiful it looks with the avatar control on the object page.

Saturday 3 October 2020

Introduction to SAP BRF+/BRFplus & why is it so popular in SAP World !!

Introduction:

◉ BRF+ stands for Business Rule Framework Plus which provides a comprehensive application programming interface and user interface for defining business rules

◉ It enables you to define business rules without the need of wiring ABAP code.

◉ The generated Business Rules can be incorporated into other SAP programs or Substitution/Validation rules.

Friday 2 October 2020

** TEAM FPM ** Get in Touch with the New FPM Mobile Enabler!

How to easily adapt your FPM applications for mobile devices.

Ever wondered how to transfer your existing FPM applications to a mobile environment? Have a look at the example below for a quick look at how to do just that using the new FPM Mobile Enabler.

I’m using an FPM test application that uses a Search GUIBB and a List ATS GUIBB to display hardware products. The list contains quite an extensive number of columns. Underneath the list a Chart GUIBB shows the products by supplier.