today we launched a new version of the ABAP development tools for eclipse. You can install the version 2.31 from our common update site SAP Development Tools for Eclipse. With this version we now also support the latest eclipse version 4.4. called Luna. A good overview about the new standard eclipse features in Luna can be found here: Eclipse Project Luna – New and Noteworthy
Besides the support for Luna we have integrated some nice new features for you as an ABAP developer. But be aware that these features only run on the latest AS ABAP support package level of 7.4 release which is SP08. If you don’t have such a system in your landscape we will offer you a trial version (www.sap.com/abaptrial) where you can try out these new features. Today starts our new Open SAP Course (free of charge) which is also based on the new eclipse version.
- Creating Text Elements in Reports via the Quick Assist
- Support for multiple used includes
- Brand new SQL Console
- Display ABAP Sourcecode in a web browser
- Switching between active and inactive version in editor
- Display longtext documentation in Elementinfo (F2)
- Filter your Where-Used Results
- Improve your code with the ABAP Test Cockpit for Eclipse
Creating Text Elements in Reports via the Quick Assist
One of my favorite features in eclipse is the quick assist which is available in the ABAP editor by pressing CTRL-1. This friend helps me in a lot of situations to code much faster. For example when I want to create a new attribute or method in my class the quick assist helps me in generating the needed code of the declaration. Even refactoring tasks like renaming of components or extracting variables or methods are available via this helpful function. For a short refresher of the quick assist you can have a look on our nice short little videos:
With AS ABAP 7.40 SP08 we now also support maintaining text elements of reports via the quick assist. How does this work?
Lets have a look on a typical pitfall in ABAP when defining UI texts in a report:
Damn ! Forgot to define the text element in the text pool. Thanks to the ABAP Test cockpit and the integrated SLIN check that tells me that I have to correct that. But how can I do that? There is no editor for text elements available in eclipse. Okay I use the SAP GUI and throw the eclipse away. Nooooooooooooo ! Just press CTRL-1 on the text in the editor and you will find the solution:
When choosing the offered option in the quick assist popup the text will be created in the text pool. After the text is created you can also use the quick assist to change the text via pressing CTRL-1 or you can delete the text in the code.
In that case you will see the text which is behind the text element number via the element info popup (Shortcut F2)
Support for multiple used includes
Another feature which is often requested by the community is the support for multiple used includes. In ABAP you are using includes on the one hand side to structure your code, e.g. by extracting form routines in a specific include. On the other hand includes are often used to provide reusable modules that can be included in several reports or function modules. One personal comment from my side: This kind of reuse option is NOT recommended. Please use classes or function modules when you want to provide reusable components.
But nevertheless we will support the multiple used includes with 7.40 SP08 also in eclipse. The challenge for the development tools is that the developer has to specify the main program so that the syntax-check, navigation etc. is working correctly in the editor. To specify the main program of an include you go into the editor of the include and open the properties view. On the properties view in the Tab “Source” you will find the input field to specify the main program.
Brand new SQL Console
The secret of good performance in your application is to push down logic that is needed for data retrieval as much as possible towards the database. Especially when working with big data in HANA highest priority is to execute most of the data retrieval code in HANA and not in the application server. In AS ABAP 7.40 we did a lot of enhancements in ABAP so that you are able to optimize your application code. A good overview about the new language feature is given by Horst Keller in his blog: ABAP Language News for Release 7.40, SP05
From the tooling perspective we introduced the data preview already for you with SP05. With the data preview you can display database content from a table or an view directly in your eclipse IDE. A very good overview about the tool is given in the video Data Preview within ABAP in Eclipse – YouTube by my colleague Raghuvira Bhagavan.
With SP08 we are bringing a new tool for you that enables you to easily execute arbitrary SELECT statements on the database without writing an ABAP report. The new SQL console can be reached per system by right-clicking on the ABAP project name in the eclipse project explorer. Just choose SQL console and the tool opens up in the editor pane. The SQL console consists of an editor where you can enter the SQL code and offers you functions like code coloring, code completion and syntax-check for your convenience. The statement can be executed and you will see the result in the grid on the right hand side:
The tool also offers you enhanced features like:
- Statement history in order to go back to former SQL statements
- Favorites to permanently store SQL statements
- Performance data to analyse the runtime behavior
It really makes fun to play around with the new SQL features by using the SQL console.
Tip: You can also open the SQL console from the data preview view. That’s very nice because the data preview automatically generates you the SQL statement according to your filter settings.
Display ABAP Sourcecode in a web browser
I am pretty sure you are already using our cool hyperlink feature within ABAP in Eclipse. You can create links to development objects that enables you and your colleagues to open an ABAP object in the IDE just by clicking on the link. This might be very helpful when you want to share a pointer to a specific code line in an ABAP report with your colleague. If you don’t know this feature please have a look into blog How ADT links change the way you work by Thomas Alexander Ritter to understand the whole story.
But the ADT links have the problem that the link opens the editor only in your eclipse environment. But let’s imagine you want to share a link with a colleague that does not have eclipse installed on his PC. Or you want to check a report that you have developed but unfortunately you are already sitting in the bus on your way home and you only have your mobile phone with you. Could you imagine that in that case you can also display the source of your report without an IDE?
With AS ABAP 7.40 SP08 it is now possible to create HTTP Links to your development objects. Therefore we offer you a new option in the eclipse project explorer that helps you to generate these links. Just right-click on a development object in the project explorer or in the editor tab to generate such an hyperlink:
The generated hyperlink looks like:
and you can use it to open the source in a web browser:
By clicking on the link ‘Open in ABAP in Eclipse’ in the upper right corner of the page you can open the object in your Eclipse installation.
Important Note: Before you can use this feature you have to enable the underlying http service in the ABAP backend via transaction SICF. The service that you have to activate: sap->bc->adt
Switching between active and inactive version in editor
A small but very important feature when looking on the wishlists of our developers is the possibility to toggle between the active and the inactive version of a development object in the editor. Up to now this was only available via the version history where you see the inactive and the active version with the possibility to do a version comparison:
As this feature is a little bit hidden for the developer we now offer a function directly in the context menu of the editor:
Display longtext documentation in Elementinfo (F2)
With AS ABAP release 7.40 we introduced a new concept for documenting ABAP source code called ABAP Doc. The developer is now able to document his development artifacts directly in the code editor and the documentation is stored within the object. Within the ABAP Doc comment you can use HTML tags to format your documentation like in this example here:
One of the benefits of ABAP doc is that the consumer of a development object can see the documentation in the element info when pressing F2 in the eclipse editor. This is really helpful because you don’t have to navigate to the other object just to see the documentation.
But wasn’t there already a concept for documentation in the ABAP stack since years based on SAP Script?
Where can I find this kind of documentation?
With SP08 we have integrated the long text documentation also in the element info via this link. By clicking the link you will see the long text also in the popup screen.
Filter your Where-Used Results
When triggering the Where-Used function in the ABAP workbench you have several options to restrict the search result, e.g. you can restrict the search for specific object types or specific packages:
This kind of search restriction was not possible within Eclipse. So we decided to offer this functionality now also with the new client. In Eclipse you first trigger the where-used on a development object and once the result is displayed in the search view you can filter the hit list by specifying the following filter options:
In addition to the filtering we also enhanced the result list view of the where-used. For example you can now trigger the where-used search for objects displayed in the search result view which is quite convenient for the developer.
Improve your code with the ABAP Test Cockpit for Eclipse
Last but not least we also renewed the user interface of the ABAP test cockpit within eclipse. The ABAP test cockpit is the tool of choice when it comes to manage the code quality in your development landscape in the area of programming standards, security checks and performance checks. From the check infrastructure it is still the code inspector that does the quality checks in the ABAP backend. But we added an infrastructure that allows you to run central quality checks in your Q-systems and your developers can monitor the results in their development environment. A very good overview about the benefits is given by Christopher Kaestner in the blog ABAP Test Cockpit – an Introduction to SAP’s new ABAP Quality Assurance Tool .
One aspect of the tool is the tight integration with the developer tooling in eclipse. On the one hand side the developer is able to check the quality of the code he is responsible for but he can also monitor the results of central check runs of the quality system.
A.) Detecting quality issues
There are several options for the developer to check the code quality:
1.) He runs the quality checks on the object he is currently working on directly from the editor. This should be done ideally on a regular basis during development.
The check can also be done on package level via the project explorer via the same menu item.
2.) Before releasing a transport request the developer should check all objects contained in the request. This can be done in the transport view in eclipse:
3.) Developer should check regularly the results of the ATC runs in the central Q-system. This can be done via the ATC result browser in eclipse where he sees the erroneous objects he is responsible for:
Once the developer has findings in the Q-system he directly can trigger a recheck of the objects in his development system and can go on to solve the issues.
B.) Solving the ATC issues:
The result of a manually triggered check run (RunAs->ABAP Test Cockpit) is displayed in the ATC problems views with detailed information about the finding and the possibility to easily navigate to the source code position. The ATC problem view is the worklist for the developer to solve the quality issues.
Starting from the Problem View the developer can fix the issue manually in the editor or can do it by using the Quick Fix option as described in the chapter above to create text elements. There might be situations where a fix of the issue is not possible or not appropriate. Therefore the ABAP test cockpit offers the possibility to create exemptions for this source code artifact so that the finding will be ignored in the next check run. The creation of exemptions is done directly in the problems view in eclipse via right-click on the finding:
We hope that the new tooling will help to improve the overall code quality in your development landscape.
or you watch our brand new video:
So, that’s it for the overview of the new features of the new ABAP in Eclipse client for AS ABAP 7.40 SP08.
We hope you will enjoy the new features and very important: Give us feedback.