SAP S/4HANA 2024 : The Ultimate SAP Custom Code Migration Guide using KTern
One of the most important concerns for organizations looking to move from the traditional SAP ECC to S/4HANA is SAP Custom Code Adaptation. But, why is it a concern? Why is SAP custom code remediation such a nightmare for ABAPers and Project Managers? And, why should you adapt your SAP custom code during the system conversion process?
You would have invested heavily in your ABAP custom code developments for the past several years of using SAP. Traditionally, in the SAP ERP business suite, you can look into the standard SAP code, modify or enhance it to suit your business needs.
But, moving to SAP S/4HANA is a whole different ball game. For years, both SAP and the SAP partners have constantly under-represented the complexity of custom code remediation. As you start planning your move from ECC to S/4HANA, you begin to realize that a very large number of custom objects and programs will need to be adapted. The custom code in ECC may or may not be compatible with S/4HANA. A few custom codes may not perform as expected or may result in errors and dumps. Therefore, the custom ABAP code needs to be remediated/ adapted to S/4HANA.
Table of contents
- Overview of SAP S/4HANA
- The SAP custom code migration process
- An example of custom code impact
- How to migrate your SAP Custom Code to S/4HANA using KTern?
- SAP Custom Object Analysis
- Inferences from SAP Custom Object Analysis
- SAP Custom Code Impact Analysis
- Custom Code Dashboard
- Custom Code Information Wizard
- Inferences out of Custom Code Impact Analysis
- SAP Custom Code Remediation
- Custom Code Information Wizard
- Benefits of SAP Custom Code Remediation using KTern
- Project Management Features of KTern with respect to Custom Code Migration
- Custom Code Dashboard
- Collaboration
- Custom Code Sign-off Wizard
- How is KTern’s Custom Code Migration different from other products in the market?
- Next Steps
Overview of SAP S/4HANA
- SAP S/4HANA is the next generation of SAP Business Suite, designed to help you run simple in a digital and networked world.
- It is built on our advanced in-memory platform, SAP HANA, and offers a personalized user experience with SAP Fiori.
- With the new business functions and features in SAP S/4HANA, you can gain insights in real time, make decisions quickly, and accelerate business processes.SAP S/4HANA provides a single source of truth for all your data with integrated analytics and reporting powered by SAP HANA.
- This gives you a complete picture of your business so you can make decisions based on up-to-date information.
- The integrated suite also helps reduce complexity and costs while increasing agility.
The SAP custom code migration process
The custom code related process basically consists of two major phases:
Before SAP S/4HANA system conversion
During the assessment and preparation phase of the conversion, you can assess your system and get rid of the unused custom codes and objects. You can also determine the custom codes which should be adapted to S/4HANA in this stage.
During the SAP S/4HANA system conversion
During the realize phase of the system conversion, you must adapt or remediate your custom code to suit the new SAP S/4HANA software. You must also optimize the code performance for the HANA database.
You can use KTern during both the Custom Code Analysis phase and the Custom Code Remediation phase. However, the process of custom code analysis is different than actually performing the code remediation. You can find out more on SAP Custom Code Impact Analysis using KTern in this article. In this article, we will explain how KTern automates the Custom Code Remediation process. You can perform custom code remediation in the Explore and Realize phase of the Activate methodology
The SAP Custom Code Migration |
Before SAP S/4HANA system conversion |
During the SAP S/4HANA system conversion |
Preparation phase of the conversion | Realize phase of the conversion |
Get rid of the unused custom codes and objects | Adapt or remediate your custom code |
Determine the custom codes | Optimize the code performance for the HANA database |
An example of custom code impact
One of the simple examples of the impact of custom code in S/4HANA is the material length field extension from 18 to 40. So, what is the impact of this field length extension? If the custom-developed material numbers of 18-character length are used along with the new material number of 40-character length, then one of the following will happen:
- Data may be lost while moving the material number from 18 to 40 characters
- Type conflicts may occur if the material number field is passed as a parameter to a program
- Length conflicts at comparison with SAP material number
- Length conflicts at concatenation with SAP material number
In all the above cases, the custom code is incompatible. You must modify and redefine your custom material number and code to the new S/4HANA material number type.
This is just one example. Similarly, there are several changes and simplifications that occur while moving to S/4HANA. There may be changes in the field type, field length and tables. Also, some fields or tables may have been removed altogether, some tables may have been merged etc. It is necessary to determine the amount and impact of such changes before moving to S/4HANA. Later, during the actual conversion, you must remediate the custom code so that it is compatible with S/4HANA.
How to migrate your SAP Custom Code to S/4HANA using KTern?
Custom Code Migration is the most crucial and time-consuming aspects of a system conversion project. It can make or break your Digital Transformation Project. There are several questions that a Project Manager and an ABAP lead would have with respect to SAP custom code remediation. Some of them being:
There are several questions that a Project Manager and an ABAP lead would have with respect to custom code remediation. Some of them being:
- How do I know what changes to make in the code?
- How do I prioritize changes in order of importance?
- How much effort should I plan?
- How do I track the progress?
- How do I know the performance of the code once it is changed for the SAP HANA database?
The answers to all the above questions can be easily measurable using KTern. Hence, KTern is the one single tool that you will require to automate and manage your entire system conversion.
Typically, in a system conversion project, the ABAPERs go through each custom program/ code and identify the incompatible custom code for S/4HANA. After identifying them, they manually do the necessary changes to make the custom code compatible and move the changes to Transport Requests (TR). But, with KTern, you can automate this entire process, thus saving much of your time, effort and resources.
KTern performs the SAP custom code migration in three steps:
- SAP Custom Object Analysis
- SAP Custom Code Impact Analysis
- SAP Custom Code Remediation
SAP Custom Object Analysis
Organizations using SAP can customize their standard business process using custom objects. Any object with a prefix of “Z” is called as a custom object. A bunch of custom objects are grouped in a custom package. Furthermore, custom-developed objects are broadly classified into six main categories as follows:
- Custom Dictionary Objects
- Custom Reports
- Custom Function Builder
- Custom Forms
- Custom Web Applications
- Custom Enhancements
Before moving to S/4HANA, it is necessary to analyze all the custom objects in order to determine the most used objects and to retire some custom objects. Without a single unified view of all the custom objects, it is very difficult to figure this out. However, KTern is here to save the day. It automates the process of custom object analytics.
The main objective of SAP Custom Object Analytics is to provide an analytical dashboard of the various custom objects present in the existing SAP ECC system. The overall custom object profile is presented to the business stakeholders in order to know the level of customizations in the system. After connecting an ECC system, KTern runs the custom object analytics check and determines the custom objects present in a system. The custom objects are then grouped based on the custom packages, the stakeholder who created it, the type of custom object and the frequency of usage.
In general, you should make the following changes and respective custom object adjustments in a system conversion project to SAP S/4HANA:
- Adjusting the custom objects to a simplified data model and simplification list in SAP S/4HANA
- Re-applying modification using SPDD, SPAU – due to software update
- Mandatory changes for SAP HANA – if the system is not SAP HANA ready
- Making the custom objects Unicode compliant – if the system is not yet on Unicode
- Optimizing the performance of custom objects
Inferences from SAP Custom Object Analysis
Analyzing the custom objects is an important step before moving to S/4HANA. With this feature of KTern, you can gain analytical insights on the following:
- Custom packages with respect to the number of objects
- Frequently used custom transactions/reports
- Top x custom object stakeholders
- Top x custom object types
- Custom objects summary, and much more
Typically, one of the first questions a stakeholder asks to determine the weight and complexity of the ECC system is: What is the total number of custom objects in the system? KTern provides the answer to the above question and much more additional insights in just a click of the button. You can also use this feature to determine the timeline and effort of an SAP S/4HANA system conversion project.
SAP Custom Code Impact Analysis
KTern automates the process of SAP custom code impact analysis. As a result, this section gives you an analytical view of the custom code present in an SAP ECC system. After connecting an ECC system, KTern runs the custom code impact analytics check and analyzes the custom programs and objects present in a system.
KTern helps you generate a list of findings where your custom code does not comply with the scope and data structure of SAP S/4HANA. It also helps in estimating the effort required for custom code adaptation.
The key activities that can be performed using KTern with respect to the custom code are:
- Identification of affected custom objects
- Scope definition of custom code migration
- Define which custom code needs to be taken to S/4HANA
- Define usage frequency
Custom code analysis parameters
- Syntactically incompatible change of existing functionality
- Functionality not available but functional equivalent available
- Functionality not available
- Change of existing functionality with a performance impact
Custom Code Dashboard
The custom code dashboard then gives an overview of the custom objects present in the connected SAP system. The analytics dashboard depicts the following KPIs.
- Custom code impact level
- Number of custom objects
- Number of impacted custom objects
- Custom objects by remediation types (simplified objects, S/4HANA syntax errors, database operations, critical statements, field length extensions, SELECT without ORDERBY)
- Impact score of each custom object
KTern’s AI-powered rule engine automatically calculates the impact score of a custom program based on its analysis parameters and the number of impact cases. For example, if the custom program has many impact cases and its equivalent functionality is not available in S/4HANA, then it is given a high impact score.
The Custom Code Dashboard also provides a chart depicting a usage vs impact score of the custom objects. This helps in prioritizing the high impact code with high frequency of usage. You can eliminate the low usage custom programs and objects after taking a call with the business stakeholders.
Custom Code Information Wizard
KTern provides the basic information on each custom program and object in the custom code information wizard. It consists of the following basic information:
- Impact and Optimization score
- Security Score
- Usage Frequency and Priority
- Stakeholders
- References and relevant discussions
Inferences out of Custom Code Impact Analysis
As discussed so far, KTern provides a detailed and comprehensive analysis of each impacted custom program and custom object. Based on the information provided by KTern, you can plan your SAP S/4HANA system conversion with confidence.
You can easily estimate the required amount of time and effort for the conversion, the number of resources required, the number of conversion runs to be planned etc. You can prioritize your custom code remediation. The high frequency, high impact score custom code and objects can be remediated first. You can also archive certain unused custom objects after evaluating its functional importance and taking a call with the business stakeholders.
KTern also provides the roadmap and effort for the S/4HANA system conversion based on the results from the custom code impact analysis.
SAP Custom Code Remediation
KTern stores the results of the SAP Custom Code Impact Analysis from the Assessment phase in the Custom Code Catalog. You can also auto-import the custom objects to perform the initial analysis. Once you have this list, you can start the SAP custom code remediation during the Explore phase.
Custom Code Information Wizard
Each custom object object and program has its own Custom Code information wizard. The Information Wizard further has three tabs:
- Custom Code Center
- Custom Code Lab
- AI-powered Remediation Engine
Custom Code Center
KTern provides the basic information on each custom program in the custom code center. It consists of the following basic information:
- Impact and Optimization score
- Security Score
- Usage Frequency and Priority
- Module to which the custom code belongs
- Custom Code type
- References and relevant discussions
In addition, the ABAP lead or the Project Manager can assign these custom codes to relevant ABAPERs (stakeholders) to perform the remediation from the Custom Code Center itself. The stakeholders can also upload files and have discussions. In short, the custom code center provides a 360-degree view on a custom program and provides a platform to collaborate seamlessly with the other project stakeholders.
AI-powered Remediation Engine
KTern’s AI-powered auto-recommendation engine provides the technical consultants with a list of remediation recommendations. Based on their assent, they can auto-remediate the code by just clicking on the auto-remediate button. The code will then be pushed into the SAP system and is recorded as a transport request.
In addition, KTern also provides the option of remediating many custom programs in one go. This can be done using the Bulk Remediation option. You just have to choose the custom programs which you wish to remediate and click on the Bulk Remediation button. As simple as that.
Custom Code Lab
Custom Code Lab provides AI-based insights of the custom code and also a development environment to edit the code manually. The key features of Custom Code Lab are:
- Code Editor
- Code Diagnostics
- Code Performance
Code Editor
This is the ABAP code editor, where the ABAPERs and technical consultants can manually remediate the code and push the code to the Transport Request. If the technical consultants want to make additional changes, in addition to those by KTern itself, they can do so from the code editor itself.
Code Diagnostics
KTern analyzes the custom code and provides the results and recommendations to optimize the code for SAP HANA in the following categories:
- Adaptation checks
- Performance checks
- SAP HANA optimization checks
- Security Audit checks
Examples of adaptation check include:
- Problematic SELECT * Statement
- SELECT . . . FOR ALL ENTRIES-clauses to be transformed
- SELECT statement with DELETE statement
- SELECTs in loops across modularization units
Examples of performance check include:
- Analysis of the WHERE clause for SELECT, UPDATE and DELETE
- SELECT statements that bypass the table buffer
- Sequential Read Access for a Standard Table
- Table Attributes check
Examples of HANA Optimization check include:
- Use of Nested SELECT loops
- Use of Secondary Indices for Searching
- Data intensive Operations in Application Layer
Examples of Security Audit Check include:
- Secure Programming: Password Security
- Use of Secure Store and Forward Mechanism
- Cross site scripting
- SQL Injection
- Input Validation
- Canonicalization
- Directory Traversal
Code Performance
KTern also provides the ABAPer with insightful information on the code performance and quality. The information such as the number of steps taken to execute, total response time, average response time, total DB time, DB time (in percentage), total sequential read time, total change time are depicted in the form of statistical widgets.
Benefits of SAP Custom Code Remediation using KTern
As discussed so far, KTern can be used in the entire lifecycle of custom code remediation – starting from custom code analysis, custom code remediation to custom code optimization.
Few of the key benefits of using KTern for custom code remediation include:
-
Reduction in:
-
Development effort for functional (mandatory) adaptations
-
Development effort for performance adaptations
-
Project cost tied to custom code adaptations
-
Number of custom code violations
-
-
Complete ownership of custom ABAP remediation project
-
Automated code fixes eliminating the risks of new errors being introduced by manual modifications
-
Articulation of impacted application areas using interactive dashboards
-
Improved application performance by remediating SQL statements
-
Enhanced application stability
-
Complete project management and governance
-
Reduction in effort and resource utilization
Project Management Features of KTern with respect to Custom Code Migration
- One of the differentiating factors of KTern is its project management and collaboration features.
- A Digital Transformation project is not dependent only on data and process flows alone.
- One of the critical factors for the success of any Digital Transformation project is the active collaboration of the stakeholders. The same holds true for an S/4HANA conversion project, which forms the core of your digital enterprise.
Custom Code Dashboard
The custom code dashboard then gives an overview of the custom objects present in the connected SAP system. The analytics dashboard depicts the following KPIs.
- Custom code impact level
- Number of custom objects
- Number of impacted custom objects
- Custom objects by remediation types (simplified objects, S/4HANA syntax errors, database operations, critical statements, field length extensions, SELECT without ORDERBY)
- Impact score of each custom object
The Custom Code Dashboard within KTern also provides a Resource Utilization table. It has a list of all the ABAPers and Technical consultants working in the project along with the number of custom programs allocated to them. It also tracks the progress of each stakeholder with respect to custom code remediation.
In other words, it makes a project manager’s job very easy as the dashboard gives an overall view of all the resources and their progress in remediating each custom program.
Collaboration
KTern saves the results of custom code analysis so that you don’t have search for them elsewhere. The Project Manager can select the custom programs from the catalogue and assign it to the respective ABAPers to perform the code remediation. The custom program can also be created as a task, an issue or a test case as well. You can upload files, relevant OSS Notes and have discussions on the forum within the application itself. Also, the dashboards give an overall view and helps to keep an eye on the overall progress of the project.
Custom Code Sign-off Wizard
Custom objects impacted depends on the customization and age of the system. The signoff wizard helps the project manager from the system integrator side to easily decide on the sign-off from the customer. The sign-off wizard helps to find out whether the stream of custom object operations (in modules, business processes) are completed or not.
How is KTern’s Custom Code Migration different from other products in the market?
Custom Code Analysis
It is an essential pre-check before migrating to S/4HANA. Tools such as Gekkobrain and Panaya perform a check and provide the impact of custom code migration to S/4HANA. Both the products use SAP’s standard tools which consume a lot of time to set up the infrastructure and install relevant OSS Notes. It takes three or four weeks to complete this assessment.
However, the differentiating factor of KTern is that it completes the custom code impact analysis in a span of few minutes. The time factor and ease of usage in KTern makes it one of the most user-friendly SAP S/4HANA conversion tool in the market.
In addition, KTern provides a detailed analysis of each custom program and specifies its impact score, optimization score, usage frequency, stakeholders and much more. KTern also specifies the functional module to which a particular custom code belongs. All this will help in better decision making and planning the route to S/4HANA.
Custom Code Remediation
Custom Code Remediation is the most crucial and the most time-consuming activity in an S/4HANA system conversion project. It can make or break your Digital Transformation project itself. Hence, it is essential to get it right.
There are several products in the market which aid custom code remediation. Two of the most prominent being Gekkobrain and Haneya. Gekkobrain is a custom code adaptation tool, which finds, analyzes, highlights and estimates issues in custom code and modules before generating a project plan with recommended sprints. HANEYA is a Custom code remediation tool that remediates custom code incompatibilities, replaces obsolete transactions and obsolete tables, and updates security roles automatically.
However, the differentiating factor of KTern is the speed with which it performs the custom code remediation. Each custom code can be remediated in a span of few minutes.
Another differentiating factor of KTern is it project management and collaboration features. A Digital Transformation project is not dependent only on data and process flows alone. One of the critical factors for the success of any Digital Transformation project is the active collaboration of the stakeholders. The same holds true for an S/4HANA conversion project, which forms the core of your digital enterprise.
KTern saves the results of custom code analysis so that you don’t have search for them elsewhere. The Project Manager can select the custom programs from the catalogue and assign it to the respective ABAPers to perform the code remediation. The custom program can also be created as a task, an issue or a test case as well. You can upload files, relevant OSS Notes and have discussions on the forum within the application itself. Also, the dashboards give an overall view and helps to keep an eye on the overall progress of the project.
Next Steps
Now that you know how KTern performs custom code remediation, you might want to get a first-hand feel of KTern and its other several other modules which help automate and govern SAP projects from start to finish. You can get started with the same at Getting Started. Alternatively, if you would like a guided demo of the product from one of our product engineers, kindly get in touch with us by submitting a message at Contact us.