Show TOC

Where-Used FunctionLocate this document in the navigation structure

The where-used function enables you to determine the development objects that use a specific object, thereby making the dependencies between the development objects clear.

Availability

You can start the where-used function from the following locations:

  • Project explorer
  • Outline
  • Source code editor
  • Another where-used result

You can use the where-used function for:

  • Main ABAP development objects, such as function groups or global ABAP classes
  • Subobjects, such as attributes, messages, function modules as part of a function group, or class methods as part of a class, and so on
Note The improvements in the Where-used view like the general and filter functionalities from the toolbar and context menu are provided for SAP NetWeaver Release 7.31 SP14 and higher as well as Release 7.40 SP08 and higher.

Execution

You can trigger the where-used function in any of the following ways:

  • Choose the icon Get Where-Used List... in the toolbar.
  • Use the shortcut Ctrl + Shift + G
  • In the context menu, choose the entry Get Where-Used List.

Display of Search Results

The findings of a where-used search are displayed in a hierarchical tree in the Search view. They represent the relationships between development objects and their elements.

The Search view is divided into the following levels:

  • Summary of the related development object or element and number of matches
  • Display of the related development objects
  • Display of the occurrences in a subtree

In addition, on the first level you will also see the number of matches and the objects where a match was found.

Note The number of related objects is automatically evaluated and displayed. ABAP Development Tools (ADT) displays a question mark as placeholder for the number of matches for those levels you have not selected thus far. The reason for this is that evaluating the number of matches is time-consuming. To evaluate and display this number, select Expand Tree from the context menu of the relevant subtree.

General Functionalities (Toolbar)

From the integrated toolbar in the Search view, you can do the following:
  • Navigate to the next or previous match
  • Expand or collapse a main tree or a subsequent subtree
  • Show or hide the ABAP package hierarchy
  • Rerun the search execution
  • Stop the current search
  • Display or clear as well as navigate in the search result history
  • Pin the search view
  • Display the search result view as list or tree

If you hover a finding, a tooltip is displayed that provides you with further information.

In addtion, variables with write or read-only access are highlighted with a coloured background.
Note The color settings can be defined in the Start of the navigation path Window Next navigation step Preferences Next navigation step General Next navigation step Editors Next navigation step Text Editors Next navigation step Annotations End of the navigation path preferences.

Filter Functionalities (Toolbar)

You can open the filter dialog from the integrated toolbar in the Search view to limit the search.

You can limit the search with the following criteria:

Note Use Ctrl + Space to open the Content Assist in order to consider existing entries.
  • Package(s): Select the main ABAP package or specific subpackages in which you want to search.
  • Object Type(s): Select one or more development object(s), like ABAP classes, ABAP interfaces, and so on, that are relevant for you.
  • Responsible User(s): Select one or more users that are involved in your project and might have created or edited the relevant development object(s).
  • Code Category: Select one of the following categories to define the code area you want to investigate:
    • Production and Test Code
    • Production Code Only
    • Test Code Only
  • Exclude Indirect References: By default, the where-used result also contains indirect usages. Perform a selection in order to minimize the number of results that relate to components like structures, and so on, or ABAP classes.
    Note

    When you search for a structure, for example, you will get:

    • Direct usages: DATA: speed TYPE zmg_speed.
    • Component usages: speed-value = 50. “value is a field of the searched structure
    • Other indirect usages: drive( speed ). “speed is typed with the serched structure

    You can exclude the indirect matches by selecting the Exclude indirect usages checkbox.

Other Functionalities (Context Menu)

You can run an ABAP unit test or search for another usage from the context menu of a development object or its elements that are displayed in the search results.