SAP ABAP Business Add-Ins implementation

This concept is in continuation with SAP ABAP BADI FILTER DEPENDENT PART TWO and it may be more convenient if you to go through it before proceeding to this concept.

If you want to use a filter-dependent Business Add-In, you will need an implementation for each relevant filter value. Multiple filter values may use the same implementation, however.

When implementing a filter-dependent Business Add-In, proceed as follows:

1. Create an implementation by referring to the corresponding Business Add-In definition.

2. Enter a characteristic filter value for the implementation, or choose F4 and select a value from the list of possible entries displayed. In principle, it is possible to define multiple characteristic filter values for each implementation.

3. Use the Class Editor to fill the interface method.

In the string conversion example, you would make the following entries for each country:
BRD:
translate parameter to upper case.
Ireland:
translate parameter to lower case.
Italy:
translate ...

4. Repeat steps 1-3 for each implementation that you create.

5. Activate your implementations.

Now, whenever you execute the report program described above, different country-specific implementations are executed.

You can specify generic filter values for the implementation of a Business Add-In, which means that you can use the special character "*". You can use the asterisk to represent any part of a filter value. A generic filter value can be replaced by different values which may be found in the
database.

You can show and hide short texts for filter values by double-clicking the corresponding column.

As far as extendible filter types are concerned, it is also possible to edit short texts.

Extendible Filter Types

If you flag a filter type as being extendible, it is also possible to create implementations for filter values that did not exist so far. When you assign the extendible attribute to a filter type, the Implementation menu option in the BAdI Builder is replaced by Filter value. If you choose Filter value ® Create and enter a filter value that did not yet exist (you do not need to specify the name of the implementation), the system takes you to the transaction for implementing Business Add- Ins. You can also use transaction SE19, as usual.

The assignment of the extendible attribute is subject to the following restrictions:

The domain to which the extendible filter type refers must have the following properties:

1· The domain is linked to a cross-client value table. This value table has exactly one key field which has the data element of the filter type as its field type.

2· The domain has a text table with two key fields. A key field has the filter type as its field type, and a key field is a language field. To mark a field as a text field, a field must exist in this table that contains the string 'TEXT' or 'TXT as a partial string. In the Dictionary, the text table must be assigned to the value table.

3· The delivery class of both tables must be "E" or "S".

All filter values that are created in the context of an extendible filter-dependent Business Add-In must not yet occur in the value table and are added to the value table when the data is saved.

Analogously, the values are removed from the value table when the implementation or the entire Business Add-In is deleted. The same applies to the text table.

Special Characteristics of Country-Specific Business Add-Ins

The standard system contains a Business Add-In which provides an interface for integrating additional postal checks of the address data through external tools. This Business Add-In is called Address-Check.

This example uses the data element INTCA (ISO code of the country). Since SAP recommends complying with the international ISO standard for country-specific queries, you should use the data element INTCA also for Business Add-Ins. The ISO code of a country key would be, for example, US instead of USA, or DE instead of BRD.

Before the Business Add-In is called from within the application program, you must determine the ISO code of the country by submitting a SELECT statement against table T005 (field INTCA).

Then you can pass the filter value as exporting parameter.
15.5

You can go through entire BADI COURSE HERE.


MySAP CRM business intelligence at work
CRM data administration in mysap and business intelligence

No comments :

Post a Comment