Skip to Content

Today SAP released the new support package 05 for NetWeaver 7.4. I’m very happy to announce that also a new version of the ABAP Development Tools for Eclipse is generally available on the SAP Service marketplace (valid S-user required). Just navigate to the SAP Software Download Center and ‘Search for Software Downloads‘ using the keywords ‘ABAP Eclipse‘. This time you will find 2 versions of 2.19. The version 2.19_Juno is in case you want to use the older eclipse version Juno. But we recommend to move to Eclipse Kepler. A detailed installation guide is available as attachment of https://service.sap.com/sap/support/notes/1950493 .

You will find the new packages ADT 2.19 also on our SAP tools update site: SAP Development Tools for Eclipse

The new version comes along with a bunch of bugfixes and for sure with a nice set of new features.

The new features are available with NW 7.4 SP05 and we managed to downport most of them also to NW 7.31 SP11.

A general overview about the Feature availability matrix of ADT you can find in this blog:

ADT Feature Availability Matrix for AS ABAP Releases

So let’s have a look on the new cool features of ADT 2.19:


Quickfixes for creating function modules and includes (7.4 SP05 + 7.31 SP11)

A very often used functionality in the ABAP workbench is the possibility to create new development objects just by double-clicking on the object name in the editor. In case the object does not exist the creation wizard comes up and you can define the object.

In Eclipse we support this functionality via the Quick Fix action. For classes and interface this functionality is already available a while ago. Now we support also the creation of function modules directly from the source code editor:

  /wp-content/uploads/2013/12/blog1_345276.png

And the creation of includes in the editor is also supported:

/wp-content/uploads/2013/12/blog2_345345.png

Generating constructor methods for ABAP classes (7.4 SP05 + 7.31 SP11)

A very helpful new function of the ADT is the possibility to generate constructor methods via the Quick Fix functionality. Just position you cursor on the name of the class within the eclipse class editor and press CTRL-1 (Quick Fix). The tool provides you the following options:

/wp-content/uploads/2013/12/rfm1_347124.png

  • You can create a class constructor
  • You can create an instance constructor
  • You can create a static factory method

In case you create an instance constructor or a factory method the tool asks you which attributes you want to initialize in the implementation. Therefore a popup comes up where you specify the attributes.

/wp-content/uploads/2013/12/rfm2_347125.png

Once you did that and press “Finish” the editor creates the definition of the constructor method for you including the input parameters based on the attributes you have chosen. Also the method implementation is generated into your code:

/wp-content/uploads/2013/12/rfm3_347147.png

Easily create attributes and parameters for ABAP classes in the eclipse editor (7.4 SP05 + 7.31 SP11)

Now it is possible to very easily create new attributes for classes by using the Quick Fix action of the eclipse editor. So let’s assume you are implementing a new method and you need a new attribute for the class. In that case you just enter the name of the attribute in the editor and press CTRL-1 (Quick Fix). The tool now detects which actions make sense for that source-code position and offers these options in a small popup:


/wp-content/uploads/2013/12/decl1_347175.png

When you choose the option “Declare attribute …” the editor creates the data declaration for you in the private section of the class. In case you want to change the visibility of the attribute to public we offer an additional Quick Fix on the declaration of the attribute to change the visibility:

/wp-content/uploads/2013/12/decl2_347192.png


Another Quick Fix function which is offered with ADT 2.19 is the possibility to add new parameters to a method. So let’s assume you are implementing a method and you need a new importing parameter or you want to add a returning parameter. Again you position the cursor on the name of the parameter in the editor and click CTRL-1 (Quick Fix). Now you get additional options in the popup:


/wp-content/uploads/2013/12/decl3_347194.png 

When you choose “Declare importing parameter…” the editor adds the parameter to the signature declaration. We also have a small video for you on Youtube that will show you these features live in the system: Refactoring with ABAP in Eclipse – YouTube

Creating bookmarks via the project explorer (7.4 SP05 + 7.31 SP11)

You can now add bookmarks to any ABAP artifact via the eclipse project explorer. To add a bookmark, select the artifact in the project explorer, and choose the context menu “Add Bookmark” and give a name of your choice:

/wp-content/uploads/2013/12/bk1_347288.png


This ABAP artifact is now listed in the eclipse bookmarks view and you can easily open the editor by double-clicking on this artifact at any point in time.


/wp-content/uploads/2013/12/bk2_347289.png


More details you can find in the blog from my colleague Raghuvira Bhagavan Bookmarks in ADT 2.19



Displaying enhancement implementations in the eclipse editor (7.4 SP05 + 7.31 SP11)

With ADT 2.19 we now also support the display of enhancement implementations in the eclipse editor. In contrast to SAP GUI the source code is not merged in the source code of the enhanced object but all implementations are indicated by a marker in the editor’s ruler. You may know the icon of the marker already from the workbench.

/wp-content/uploads/2013/12/enh1_347304.png

To display the source code of the source code plug-in you just need to hover over the marker in the editor’s ruler. A small window comes up and displays the code and also some metadata like the name of the enhancement and the activation state.

/wp-content/uploads/2013/12/enh2_347305.png

Currently, we support all kinds of source code plug-ins in classes, programs and function groups:

  • explicit: at statements ENHANCEMENT-POINT or ENHANCEMENT-SECTION
  • implicit: e.g., begin and end of a method, function module, sub routine or the end of an include


For sure this is only a starting point. In future releases we will also better support the editing of enhancements in eclipse.

Watchpoints in the Eclipse Debugger (7.4 SP05 + 7.31 SP11)

With ADT 2.19 we also enhanced the featureset of the ABAP debugger in Eclipse. When debugging ABAP code, you can now use watchpoints to track the value of individual ABAP variables. The ABAP debugger stops as soon as the value of a watched variable has changed.  In a running debug session use “Set Watchpoint” in the context menu of ABAP source code editor or in Variables view.


/wp-content/uploads/2013/12/wp1_347067.png



Furthermore you can specify conditions for watchpoints. The runtime environment checks whether this condition is fulfilled and only in that case the debugger stops. The condition is specified within the breakpoints view where also the watchpoints are listed. After you have entered the condition don’t forget to save the changes with the save button of the eclipse IDE !  



/wp-content/uploads/2013/12/wp2_347097.png


When the condition is fulfilled the debugger stops and you can see the related source-code line with a specific watchpoint icon.


/wp-content/uploads/2013/12/wp3_347082.png




Edit internal tables in the debugger (7.4 SP05 + 7.31 SP11)


Another heavily requested feature in the eclipse debugger is the possibility to manipulate internal tables in the debugger variables view. With ADT 2.19 we support now insert, change and remove lines from internal tables within the debugger. When you are in the debugger you can double-click on an internal table in order to see the content in the ABAP internal table viewer:

/wp-content/uploads/2013/12/itab1_347083.png

When you right-click on a cell in the table view you find several options to manipulate the table:

/wp-content/uploads/2013/12/itab2_347096.png

  • “Change value…” allows you to change the value of the field directly in the table (You can also use shortcut F2)
  • “Insert Row…” allows to insert or append a new row into the table
  • “Insert Row from Selection” allows to insert or append a new row into the table based on the values of the selected row
  • “Delete Selected Rows” allows you to delete rows from the internal table (You can also use the shortcut Delete)
  • “Delete Rows…” allows you to delete a range of rows from the internal table
  • “Show in Variables View” allows you to display the content of the table cell in the variables view
  • “Go to Line” allows you to set the table selection into a specific table line.
  • “Export to File” allows to export the whole table into an Excel file


ABAP Codesearch


Searching within source code was up to now nearly impossible with the ABAP development for Eclipse. The only offered solution was to search within one editor tab via CTRL-F. But what about searching the whole source repository in a few seconds for a specific code fragment or comment? With SAP HANA we now have the possibility to provide such a service also for you as an ABAP developer in Eclipse. With ADT 2.19 and NW 7.4 SP05 we offer you a new search capability that searches the whole source code repository for a given code fragment. In the following example we want to find all places in the code where we select for entries in SFLIGHT table. In order to do so you just open the standard search dialog in ABAP in Eclipse via CTRL-H or via the related button in the toolbar and choose ABAP Source Search:

/wp-content/uploads/2013/12/search0_346400.png

This will open a dialog where you can enter the search string. You can also specify the number of maximum hits and the ABAP project for which you want to start the search:

/wp-content/uploads/2013/12/search1_346401.png


After pressing the Search button the results will be displayed in the eclipse search view:


/wp-content/uploads/2013/12/search2_346402.png

In the result list you already have the possibility to display the code snippet that belongs to the hit.

In addition you can also open the complete source-code editor just by double-clicking the entry in the list.

News from the Web Dynpro Tools (7.4 SP05 + 7.31 SP11)


With ADT 2.19 we also added a lot new features in the area of Web Dynpro and Floorplan Manager. Please find all the details in the blog New Features in ADT 2.19 for Web Dynpro ABAP development from my colleague Raghuvira Bhagavan



Editor for Dictionary Views


Following SAP’s paradigm shift in the way business applications are developed and executed, SAP NetWeaver 7.4 SP05 provides enhanced view building capabilities to enable developers to easily define semantically rich data models in the database. The new view building features are delivered in the context of the Core Data Services (CDS) support in ABAP. They include new join types (LEFT OUTER JOIN, RIGHT OUTER JOIN), clauses (UNION, UNION ALL, HAVING, GROUP BY) as well as support for aggregate functions (SUM, MIN, MAX, AVG, COUNT), SQL functions (SUBSTRING, MOD, CEIL, LPAD), literals, CASE statements, arithmetic expressions, cast expressions and path expressions using associations. All these new features are “open” so that developers can optimize their applications on any underlying database supported by SAP. The views can be used in OPEN SQL statements.

The enhanced view building features are provided in a new text editor for DDL Sources in ADT allowing developers to take advantage of the many source-based tools such as syntax highlighting, code completion, element info, error markers, etc. An extensive F1-help is also integrated into the text editor.


You create such a new view like every other ADT object via the Eclipse menu File->New->Other->DDL Source:


/wp-content/uploads/2013/12/ddl0_348116.png


When pressing “Finish” an editor comes up where you can enter the definition of the view in a textual way.

Here you see an example of such a new view in the DDL editor in Eclipse:


/wp-content/uploads/2013/12/ddl1_348108.png

For more information about the new view building capabilities in ABAP please have a look on that blog from my colleague Christiaan Edward Swanepoel New Data Modeling Features in SAP NW ABAP 7.4 SP5 

Or just have a look on that video tutorial:


Defining Database Procedures in ABAP classes

In order to utilize the full performance potential of HANA in scenarios of mass-data processing it is advisable to use database procedures to achieve higher performance gains. The implementation language SQLScript for database procedures shares concepts like table-like parameters and internal tables known from the ABAP world.

Starting with release 7.40 we offered the first step in using database procedures in ABAP with:

  • Database procedure development in HANA studio
  • Support for generation of a database procedure proxies in Eclipse
  • Invocation of a database procedure via the ABAP statement CALL DATABASE PROCEDURE

Although this is a rather powerful approach the development process is not optimal.

With NW 7.40 SP5 we now offer a solution where the development of database procedures is completely integrated into the ABAP development environment. Intentionally we have chosen ABAP classes as carrier for database procedure code. This means you can just tag class methods with the addition “BY DATABASE PROCEDURE” indicating, that this method is actually a database procedure and executed in the HANA engine. The main benefits are:

  • Integrated syntax-check (for active code and inactive code versions)
  • Syntax-coloring according to the SQLScript grammer
  • Background shading of SQLScript to better indicate the “language switch” from ABAP to SQLScript
  • Reuse of global ABAP types (e.g. tables, structures) in the procedure definition
  • Some (but not all) functionality of ABAP-OO, like visibility (public/private), friends, interfaces


/wp-content/uploads/2013/12/amdp_347550.png

With the next SPs, we will continue on this topic trying to improve ABAP on HANA development further on.

Please have a look on that video tutorial:


Data Preview

One of the most often used transactions in an ABAP development system is the transaction SE16  – The Data browser. With ADT 2.19 we now provide a similar tool for eclipse to display the content of views and tables. You can start the tool from the eclipse project explorer by right-clicking on the name of a database table or a database view:

/wp-content/uploads/2013/12/dp1_347365.png


By choosing the menu item ‘Open Data Preview’ a new eclipse view will be opened where you see the content of the table.


/wp-content/uploads/2013/12/dp2_347408.png


In this view you have several options to configure the display and to filter the selected data. Details can be found in the blog Introducing Data Preview in ADT 2.19  from my colleague Raghuvira Bhagavan We also have a small video on youtube for you: Data Preview within ABAP in Eclipse – YouTube



Now have fun with the new features.


Merry Christmas and a Happy New Year.

Thomas.



To report this post you need to login first.

47 Comments

You must be Logged on to comment or reply to a post.

  1. Oliver Prodinger

    Hello Thomas,

    thank you very much.

    Can you forecast which features are planned for NW 7.4 SP6 (March 2014)?

    Because we discuss, if we patch from NW 7.4, SP4 to SP5 or SP6.

    Thanks

    Oliver

    (0) 
    1. Thomas Fiedler Post author

      Hi Oliver,

      SP06 will contain bugfixes and some smaller enhancements on the eclipse client. But no major features will be delivered with SP06. Therefore I don’t see the need to wait until SP06 is available. Next planned major milestone for ABAP in Eclipse will be 7.4 SP08.

      Kind Regards,

      Thomas.

      (0) 
  2. Gaurav Patwari

    Hi Thomas,

    This is great to see such features for ABAP for eclipse. I worked on eclipse in 2004 for doing some java developments and now I am seeing back for ABAP. It feels good to see best of both world coming together.

    Kudos to you and your team for this wonderful work.

    BR

    Gaurav

    (0) 
      1. Mathias Maerker

        Actually that is an interessting question. I miss the feature but on the otherhand the Abap Docu states that it is not advisable to use “small Methods like getter and setter” because the Abap Runtime is not optimized for that..

        (0) 
        1. Daniel Ruiz

          Hi Mathias,

          True, it’s really not ‘optimized’ for objects in general I’d say… especially heavy trees, I can see a lot of degradation in my load tests… however, I cannot hurt OO principles because the engine does not ‘help’ as much it could, so the slow down is a down effect…..

          @Thomas: every single structure becomes an object so it’s quite time consuming to type the same thing over and over.. – might be the way I code, but the only references I have to structures it’s on one of the DAO abstraction classes to persist using abap sql or rfcs between systems (since I couldn’t find a remote object implementation so far)… so I kinda miss it a lot, not to say ALT+SHIFT+L (extract variable) — total deal breakers..

          πŸ™‚

          Regards,

          D.

          (0) 
          1. Thomas Fiedler Post author

            Hi Daniel,

            what do you miss for Extracting Variables? There is a Quick Fix for creating variables, attributes and constants. And you can extract a varibale based on a expression like here in my very simple example:

            Regards,

            Thomas./wp-content/uploads/2014/02/ext_391442.png

            (0) 
            1. Daniel Ruiz

              Hi Thomas,

              Yep, that’s it.. however, I would never think such function would be on quick fix since it’s more of a ‘refactoring’ function… Eclipse kinda have all plugs for this kind of stuff already, for instance on that same picture you posted ‘extract method’ works correctly on alt+shift+m — just not sure why the different approach on extract variable..

              And thanks for highlighting such.

              Cheers,

              D.

              (0) 
              1. Michael Gutfleisch

                Hi Daniel,

                in general we always try to find solutions which fit to the Java tools as well as to the SE80 and comnine the best of both worlds.

                Regarding refactorings and quickasists I need to elaborate a bit further:

                The JDK provides refactorings (e.g. extract method), quickfixes (e.g. declare variable) and other quick assists (e.g. generating getters and setters).

                Some of them are provided in the refactor menu, some of them are provided in the source menu and some of them are provided in the dynamic quickfix menu. And some of them are provided at several of the mentioned places. And moreover, when you trigger the same feature from different menus it comes along with different flavours. In my opinion this is kind of a mess. I always have to remember well, generate setter is int this menu, extract variable is in that menu and so on…

                In ADT we want to provide consistent access to all kind of quick assists at the same place. And due to the fact that it depends on the backend system which quick assists are currently available, we have to provide the proposals dynamically. A static menu (like the source or refactor menu) with a lot of entries which cannot be executed in many cases is not a good solution for that.

                Therefore, the quickfix menu (it would be better to call it quickassist menu) which you can trigger with CTRL-1 is the right place to provide all available quickassists in ADT dependant on the current cursor selection in the editor.

                Regards,

                Michael

                (0) 
                1. Daniel Ruiz

                  Hi Michael,

                  I wouldn’t even know exactly where they stay on the menus on Java/J2EE perspective since I only use keyboard shortcuts – and I don’t actually remember or in fact have ever heard of Java people feeling confused about the source menu.

                  About the menu itself, as you mentioned it’s ‘dependency’ on the back-end version, some checks must occur in the abap perspective plugin as soon you select the system you want to work… or, instead of coding such in abap classes which is back-end dependent, just push the code to eclipse directly in the plugin to refactor the source and problem solved.

                  IMO, it’s a matter of time until CTRL+1 is flooded with all sorts of different “source” functions and not real quickfixes (to fix warnings or errors) – and then again, it’s a total incorrect usage of the quickfix since by standards SAP should be marking either yellow or red the snippet which could actually be target of a quick fix, and it will be just awfully stupid to mark every possible extract method or extract variable.. AND, oh.. extract method has it’s place on the sun, with alt+shift+m.. perhaps extract variable is just the bastard son. hehe

                  All in all, it looks like SAP is breaking a standard from a tool that is full of these small standards (or ways of doing things) which adds productivity to a developer, reason why I believe SAP decided to leave se80 (thanks God) and move towards eclipse first place…

                  (either that or some developers in SAP are just being a bunch of slackers and ‘ oh, lets put this under CTRL+1 because we have a rest handler for that already ‘)

                  =)

                  Cheers,

                  D.

                  (0) 
                  1. Michael Gutfleisch

                    Hi Daniel,

                    are you aware, that JDK also provides refactorings in the CTRL-1 menu? Without having any error markers for that! They even provide “generate getters and cetters” when you place the cursor on an attribute and press CTRL-1… (so they are flooding the quickfix menu as well with incorrect usage)

                    Concerning your proposal of having the logic in the front end… that’s just not possible because the needed analysis is dependant on the backend release and can only be done using infrastructure from the backend..

                    Concerning the shortcut usage… we will provide as many of the quick assists as shortcuts as well in the future.

                    Regards,

                    Michael

                    (0) 
                    1. Daniel Ruiz

                      Hi Michael,

                      Still not convinced.. and to be honest, again I’d never use CTRL+1 ’20 times’ in a bean to create the getters / setters, usually people in Eclipse uses CTRL+1 for one hit only (if we have more than one better use a different shortcut) – and to break it down, it’s rather simple my motives, it’s not hard to understand and I believe it’s not nearly as hard as you picture to code such. (but then again, I’m not developing plugins for Eclipse)

                      And as per your commend, see Help – Eclipse Platform – you create getter and setter on quick fix for fields that are unused or invisible, in a way it proposes you ‘ hey, you have this fellow here which is not being accessed anywhere, perhaps you want to make a public getter / setter for outside access ‘. In addition, I’m fairly positive the possibility of a CTRL+1 for such would be with a highlight on the field, which doesn’t occur in ABAP perspective.

                      As far leaving code in ABAP for ‘decision making’, I can see a lot of lag in Eclipse as soon I need anything on the CTRL+1, for (instance create methods) – I know it’s not network issue and I’m running HANA which is supposed to be fast, so I’m not sure exactly why it lags, but I think it’s ABAP…

                      But with all of this said, I’d like to see a ‘generate getters and setters’ anywhere, being CTRL+1 or not. As Thomas explained, the extract variable is present on CTRL+1 and I will be using regardless my preference of being in all+shift+L or having a direct source function bound to this.

                      Regards,

                      Daniel

                      PS: As Christian mentioned down a bit, this is feedback from a long term Eclipse user (since Eclipse was released to be precise), so don’t take it too harsh and I appreciate a lot the efforts SAP is making to provide people an alternative to se80.

                      PS2: ABAP perspective needs a ‘move’ of a resource from one package to another, it’s so painful to move stuff around because objects get ‘locked’ apparently and I cannot delete and define then again in a different package.. makes refactoring a bit of a hell.

                      (0) 
        1. Daniel Ruiz

          Hi Dominik,

          I think you would be looking more to alt-shift-s+r – this would bring up a popup of every attribute you can create a getter/setter and you can select one by one in a checkbox.

          All these methods are already heavily optimized, people using eclipse have been doing this for years.. all you kinda do is, you declare the attributes, use a shortcut and you have a bean ready for use in seconds.

          Regards,

          D.

          (0) 
          1. Christian Punz

            hi Daniel,

            i am convinced that SAP is on the right track to provide a fine user experience with ABAP in Eclipse/ADT/AIE. Thanks to Thomas and his colleagues πŸ™‚

            Dear long-term-Eclipse-users (outside the SAP-world): please provide your input and experience for Thomas to further improve the ABAP-world in Eclipse! I don’t want to use SE80 any more, but I’m forced to do so often since ADT is not feature-complete yet. Thank you!

            br

            chris

            (0) 
          2. Dominik Di Lorenzo

            Hi Daniel,

            I did not use Eclipse before using ADT, so I do not know what the Eclipse-Standards are.

            Since one goal of ADT is to have one IDE for people developing Java and ABAP, I think you are right that it should be done the Eclipse-Way.

            I thought about the quick fix, because SAP implemented many useful functions there and thats where I as a pure ADT-Eclipse-User would search it πŸ™‚

            Regards,

            Dominik

            (0) 
  3. Pahwa Devinder

    Hi Thomas,

    Nice blog… thanks for posting and provide a knowledgable info.

    Could you pls. also tell if any app available for mobile devices like we’ve open source code available for android mobile phones and anyone can develop an app for his/her phone.

    So like this, Do we’ve any app available in abap or webdynpro for this.

    Thanks a ton in advance

    Devinder

    (0) 
  4. Stefan Riedel-Seifert

    Most of the new features are not working within a 7.31 πŸ™ . But, that structured bsp-pages are not correctly displayed is a very huge bug 😑 .

    To reproduce, create a bsp-page with name /folder/index.html.

    (0) 
    1. Thomas Fiedler Post author

      Hi Stefan,

      good news for you. Most of the features will be part of the next SP for 7.31.

      What do you mean with the remark concering BSP. Where are they not correctly displayed. You mean in the eclipse project explorer? Or do you mean in the area of SAP UI5?

      Regards,

      Thomas.

      (0) 
      1. Stefan Riedel-Seifert

        The goods news: bsp extension are handled corrct, but the same problem above, when displaying the mime repository/page fragments. Folders are not displyed as folders and handled like single mimes, as you can see on this picture.

        Interesting is the error, when retrieving some specific nodes (check the marked entry):

        text files, checked in as mime repository object produces errors:/wp-content/uploads/2014/02/mime_399513.png

        (0) 
      2. Martin Steinberg

        Hi Thomas,

        as I’m working with BSP since a few weeks I also have to admit, that the hierarchy could be improved. As mentioned above the pages are not shown and if you double click on an UI component it would be very helpful to open the transaction “BSP_WD_CMPWB’. The context menue doesn’t have the option “open in SAP GUI”.

        Best regards

        Martin

        (0) 
            1. Thomas Fiedler Post author

              Hi Martin,

              Stefan is right. This transaction is part of the CRM stack and not part of NetWeaver.

              For me a good candidate for your fist own AIE plugin. What do you think?

              Going Live at SIT in October. 😎

              For sure we will help with consulting.

              I think Michael Schneider has already prepared a tutorial that shows how you can realize a button in eclipse that triggers an transaction in SAP GUI. I will try to find this tutorial.

              Regards,

              Thomas.

              (0) 
              1. Martin Steinberg

                Hi Thomas,

                good idea. I’m sure there are more candidates for calling a (customer) specific transaction. Looking forward to the tutorial and thx in advance for your support πŸ™‚

                Stefan, if you are interested we can exchange experiences and ideas.

                Best regards,

                Martin

                (0) 
      3. Stefan Riedel-Seifert

        I got an oss-note (1995596) from sap help service, that prevents the adt to display the bsp tree. On the one hand a poor solution, on the other hands it corrects not the display problem for mime types and controllers. Views cannot be displayed anymore. I can not understand this behaviour, because the inplace sapgui can be displayed to edit those objects.

        (0) 

Leave a Reply