Skip to content
NextLytics
Megamenü_2023_Über-uns

Shaping Business Intelligence

Whether clever add-on products for SAP BI, development of meaningful dashboards or implementation of AI-based applications - we shape the future of Business Intelligence together with you. 

Megamenü_2023_Über-uns_1

About us

As a partner with deep process know-how, knowledge of the latest SAP technologies as well as high social competence and many years of project experience, we shape the future of Business Intelligence in your company too.

Megamenü_2023_Methodik

Our Methodology

The mixture of classic waterfall model and agile methodology guarantees our projects a high level of efficiency and satisfaction on both sides. Learn more about our project approach.

Products
Megamenü_2023_NextTables

NextTables

Edit data in SAP BW out of the box: NextTables makes editing tables easier, faster and more intuitive, whether you use SAP BW on HANA, SAP S/4HANA or SAP BW 4/HANA.

Megamenü_2023_Connector

NextLytics Connectors

The increasing automation of processes requires the connectivity of IT systems. NextLytics Connectors allow you to connect your SAP ecosystem with various open-source technologies.

IT-Services
Megamenü_2023_Data-Science

Data Science & Engineering

Ready for the future? As a strong partner, we will support you in the design, implementation and optimization of your AI application.

Megamenü_2023_Planning

SAP Planning

We design new planning applications using SAP BPC Embedded, IP or SAC Planning which create added value for your company.

Megamenü_2023_Dashboarding

Dashboarding

We help you with our expertise to create meaningful dashboards based on Tableau, Power BI, SAP Analytics Cloud or SAP Lumira. 

Megamenü_2023_Data-Warehouse-1

SAP Data Warehouse

Are you planning a migration to SAP HANA? We show you the challenges and which advantages a migration provides.

Business Analytics
Megamenü_2023_Procurement

Procurement Analytics

Transparent and valid figures are important, especially in companies with a decentralized structure. SAP Procurement Analytics allows you to evaluate SAP ERP data in SAP BI.

Megamenü_2023_Reporting

SAP HR Reporting & Analytics

With our standard model for reporting from SAP HCM with SAP BW, you accelerate business activities and make data from various systems available centrally and validly.

Megamenü_2023_Dataquality

Data Quality Management

In times of Big Data and IoT, maintaining high data quality is of the utmost importance. With our Data Quality Management (DQM) solution, you always keep the overview.

Career
Megamenü_2023_Karriere-2b

Working at NextLytics

If you would like to work with pleasure and don't want to miss out on your professional and personal development, we are the right choice for you!

Megamenü_2023_Karriere-1

Senior

Time for a change? Take your next professional step and work with us to shape innovation and growth in an exciting business environment!

Megamenü_2023_Karriere-5

Junior

Enough of grey theory - time to get to know the colourful reality! Start your working life with us and enjoy your work with interesting projects.

Megamenü_2023_Karriere-4-1

Students

You don't just want to study theory, but also want to experience it in practice? Check out theory and practice with us and experience where the differences are made.

Megamenü_2023_Karriere-3

Jobs

You can find all open vacancies here. Look around and submit your application - we look forward to it! If there is no matching position, please send us your unsolicited application.

Blog
NextLytics Newsletter Teaser
Sign up now for our monthly newsletter!
Sign up for newsletter
 

Advanced Formula Debugging with SAP Analytics Cloud

With the new update of SAP Analytics Cloud, the long-awaited possibility to debug advanced formulas has finally arrived. The developer can set so-called tracepoints in order to check the results after executing the data action. The insights gained from this help to improve the data action and fix potential problems.

However, there are some peculiarities that you, as an experienced developer, should take into account. For example, unlike debugging in FOX or ABAP, the execution of the data action is not stopped. Rather, you can analyze the changes ex post. Also, no data is physically changed. Instead, a dedicated tracing version is used.

In this article, we go into detail about tracing in advanced formulas. You will learn how to set tracepoints, what to consider when debugging loops and how to analyze the tracing results.

How to set tracepoints

As mentioned earlier, debugging in SAP Analytics Cloud (SAC) is performed based on trace points. After executing the data action in trace mode, you can check the data changes between each tracepoint and draw conclusions about the behavior of your code.

To create a tracepoint, click on the left margin next to the line number in your script. The red indicator (Trace here) appears and then disappears shortly after. When you move your mouse over the trace point, it becomes visible again. As you can see on the screenshot, the indicator appears at the end of the line. This indicates that you will see the results after the execution of this command line.

001-trace-point_debugging

You can also define tracepoints before or after each step. To do this, click the connection arrow between the steps in the left-hand area of the data action.

002-trace-points-steps_debugging

To remove a tracepoint, you can simply click on it again. Alternatively, you can use the tracing area. When you move the mouse over a trace point, the X icon appears to delete the tracepoint.

003-delete-tracepoints_debugging

You can also use the trace area to jump between tracepoints in the code. When you click on a tracepoint, the respective code line in the script is selected.

004-select-code-via-tracepoint_debugging

Please also note the following restrictions. Tracepoints cannot be set in the graphical editor. This is only possible in the script view. In addition, you can set a maximum of 20 tracepoints. However, this number should be sufficient for most scripts.

Debugging of loops

If you use loop instructions such as FOREACH, FOREACH.BOOKED or FOR in your advanced formula and want to debug them, the debugging approach is slightly different.

005-trace-loop_debugging

In order to debug such commands, you have to define so-called conditional tracepoints. You can define a maximum of 10 tracepoints.

 

006-conditional-tracepoint_debugging

When the trace is executed, the results are available for selected iterations only.

007-trace-table-loop_debugging

In the next section, I explain how you can view and analyze the results.

Analyze tracing results

After you have set the desired tracepoints, you can execute the trace to check the results. To do so, switch to the tracing view.

008-tracing-view_debugging

Here you can check the set trace points again and start the trace.

009-execute-tracing_debugging

After you set the parameters for your variables in the prompt, the data action is executed in trace mode. Note that this does not change the target version you selected. Instead, the system creates a dedicated tracing version that contains all changes.


SAP Planning tools compared - SAP BW IP vs. BPC vs. SAC

Neuer Call-to-Action


You can view the results in the Watch Area. Under Parameters, you can see the parameter values valid for execution. This includes the parameters set in the data action settings as well as the values selected in the prompt.

Under Variables you can see the values of number variables of the type "Float" or "Integer". This includes, for example, the revaluation factor.

 010-watch-area_debugging

Under Calculation scope you can view the exact scope of the calculation based on dimensions. If only one element of the dimension is affected, only its ID is displayed. If there are several elements for a dimension, their number is displayed. By clicking on the number, you can view a list of the used elements.

011-list-of-elements_debugging

Under Lookup you can view virtual variable members, such as #TotalQuantity. After you click on the number of rows, a table with the data is displayed.

012-virtual-variable-members_debugging

In addition to this information, SAP Analytics Cloud also offers an analysis window you can reach over the “Show Table” button. It displays the data for a particular tracepoint in a story-like table layout. Here you can configure the rows, columns, and filters to achieve the desired view. When you switch between tracepoints, the changes are highlighted in yellow.

013-data-changes-story_debugging

If you are working with large amounts of data, SAP recommends running the tracing in the story itself instead of in the analysis window. In the next section, I'll show you how to do it.

Tracing in the story

As you already know, a tracing version is created to display the trace log. This version can be viewed in the story. This is particularly useful when there are many values.

014-version-management_debugging

As you select the respective table, you can track the changes made via the Version Management and History options.

015-history_debugging

To do this, use the Processing Steps, which represent the tracepoints you have set. By going through the steps from bottom to top, you can see the changes directly in the story.

016-version-history_debugging

Debugging Feature - Our Summary

The debugging feature in SAP Analytics Cloud (SAC) was something I've been wanting for years. This is because the scripting logic in SAC takes some getting used to, especially for people coming from FOX programming backgrounds. Therefore, it is important to be able to understand step-by-step what the code you just created actually does and why the results differ from the expected result.

Finally, SAP has delivered. Even if the tracing approach differs from the well-known ABAP debugging, it is still helpful and provides insights into how the script works. Thus, SAC is one step closer to offering a full-fledged planning functionality.

Would you like to learn more about the planning possibilities of SAP Analytics Cloud? Are you trying to build up the necessary know-how in your department for SAP Analytics Cloud Planning? Or do you need support with a specific question? Request a non-binding consultation offer today! 

Learn all about Planning with SAP Analytics Cloud

,

avatar

Chris

Chris Fidanidis has been working in the SAP BW environment since 2007. During these years he has implemented several planning projects and used various SAP tools such as SAP BSP, SAP BW-IP, SAP BPC, SAP BW Embedded BPC. He has gained experience primarily as a developer, architect, project manager and team leader. He enjoys playing basketball and barbecue whenever possible.

Got a question about this blog?
Ask Chris

Blog - NextLytics AG 

Welcome to our blog. In this section we regularly report on news and background information on topics such as SAP Business Intelligence (BI), SAP Dashboarding with Lumira Designer or SAP Analytics Cloud, Machine Learning with SAP BW, Data Science and Planning with SAP Business Planning and Consolidation (BPC), SAP Integrated Planning (IP) and SAC Planning and much more.

Subscribe to our newsletter

Related Posts

Recent Posts