Additional Blogs by Members
cancel
Showing results for 
Search instead for 
Did you mean: 
Former Member
0 Kudos

Introduction

In ABAP, selection screen statements, SELECT queries, Making field catalogues, Upload excel files, providing layout selections on the selection screen for ALV reports, BDC code sections etc. and so on... require you to copy and paste stuff from other programs repeatedly. This is where ABAP Editor Patterns can really help.

Some such tools available so far are:

1. The ABAP Report Wizard reaches 2000 Downloads!

2.  The ABAP Join Wizard is here!

Both the wizards have been shared via SAPLink. You can get to know more about SAPLink here. To know if it is compatible with your system, refer the user documentation. If you are getting errors installing SAPLink, following links may help you: link1 , link2.

 

The Existing ABAP Report Wizard & the Join Wizard:

•·   The ABAP Report wizard, builds a simple report out of a single table or a join for multiple tables which can be edited later.

•·   Normally ABAP reports are more complex than that and they involve multiple tables and a lot of processing. If we need to make a simple report, we would prefer using the SQVI quick viewer / the SAP Query to make it fast with more features.

•·   Speaking of functionality, the Join Wizard makes a lot more sense. Like the Report wizard, this too has been built on a Netweaver 7.0 system and requires the Report Wizard to be installed.

•·   To know If the tools are compatible with your system, check if classes starting with CL_SALV* exist. This makes them compatible only with the newer systems.

•·  Apart from this, the data declaration feature is not optional. Each click to select fields makes the Wizard think for more than a second. There is no way to search for known fields on the field list.

•·  If you are too lazy, you probably don't want to the click the additional Back and Continue buttons fora simple SELECT statement.

 

Need of a new wizard

•·  After considering above issues, developers felt the need of tools with minimum components which could be easily assembled with or without SAPLink that are compatible at least with the 4.7 systems, which still are being used by many SAP customers.

•·  To overcome the above mentioned GUI drawbacks in the Join Wizard, an initiative for creating tools that meet these needs was embarked upon.

 

Start of Development

•·  I started with a SELECT WIZARD which is very similar to the Join Wizard in functionality. However, it can also be assembled manually without much trouble using the components provided in the project link below.

•·  If you have installed SAPLink, provided is a nugget to get the tool installed quickly.

•·  It has just one main screen to fill up. Selecting fields is faster. A few additions to the SELECT statement are also available.

•·  The coding is pretty easy to follow and any enhancements are welcome.

The development has been done on a 4.7 system and tested on a Netweaver 7.0 system.

I call upon ABAP developers to help the SAP community by contributing to this initiative with more such ABAP editor patterns as listed in the first few lines of this blog.

The project link: http://code.google.com/p/abap-code-patterns-bots/

The download section has all the files mentioned below.

Intallation Instructions

Create a pattern in SE38 named Z_SEL. Type *$&$MUSTER and save it.  

SAPLink users

Simply install the NUGG_SELECT_WIZARD.nugg file using ZSAPLINK program.

For non SAPLink users:

•·    Implement the Function group and its components from the project link download.

•·    Function Group  = ZFGUT_SELECT_TYPE 

•·    Function Module = Z_SEL_EDITOR_EXIT with the TABLES parameter as BUFFER.

•·    Includes F01, O01, I01

•·    Screen 9000 and its GUI.

•·    Text elements from the excel file to the Function group.

•·    Implement the relevant code and activate all of above.

Example: Simple SELECT statement on one Table.

 

 

•·     Input a table name and hit enter.

•·     If it is just one table keep the left radio button selected.

•·     If it is a JOIN, select the Join radio button.

•·     The ‘S' column, has the list of fields to be picked.

•·     The ‘W' column has fields you want in the WHERE clause.

This tool expects you to take care making sensible choices as far as syntax is concerned.

A checkbox makes data declarations optional.

 

Example: Using Z_SEL for JOINS :

Use the JOIN button to build a JOIN clause as follows. Don't forget to select the radio button next to it.

 

Come back and select the fields for the SELECT and WHERE clauses.

 

Update the code as per requirements.

 

Comments & Suggestions and contributions are welcome for taking this initiative further.

iyersubrax@gmail.com

7 Comments