By default, the Items panel and the Favorites tab of the QueryBuilder display a complete list of items from the data source, including the complete folder structure for those items, based on the permissions for the particular user. If the folder structure has many levels, then the list of folders in the Items panel and Favorites tab can become unwieldly.
You can customize the display of folders in QueryBuilder. For example, you can specify that no folder names appear in the QueryBuilder at all or that only one "root folder" is displayed in the QueryBuilder, even though the underlying structure actually contains numerous folders.
To customize the display of folders, use the methods of the oracle.dss.queryBuilder.QueryBuilder.java
class that are described in the following table.
Method | Description |
---|---|
setItemSearchPaths |
Specifies an array of folders whose names are not displayed in the Items panel in the QueryBuilder. |
setItemSearchPathNames |
Specifies an array of names to use for renaming folders for display in the Items panel in the QueryBuilder. |
setFavoriteSearchPaths |
Specifies an array of folders whose names are not displayed in the Favorites tab in the QueryBuilder. |
setFavoriteSearchPathNames |
Specifies an array of names to use for renaming folders for display in the Favorites tab in the QueryBuilder. |
Important: By default, the QueryBuilder displays items from all folders to which the user has the appropriate permissions. If you use the methods that are described in the previous table to modify the display of folders in the QueryBuilder, then the QueryBuilder displays only those items in folders whose names you have specified in the array arguments, based on user permissions. When creating the array of folder names, ensure that you do not inadvertently omit the names of folders that contain items that your users need.
For the purpose of illustration, suppose that by default, the Items panel in the QueryBuilder displays the following folders and items:
PWD_Calculations User_Pedro_Calculations Calc1 Calc2 Calc3 Global_Calculations GlobalCalc1 GlobalCalc2 XADEMO_Measures Actual Budget Sales Units Channel Division Geography Product Time
Suppose that you decide that the previous default presentation of folders and
items in the Items panel is unnecessarily complicated. Because the list
of items is not very long, you decide that hiding folder names can benefit your users.
You also decide that the calculations in the User_Pedro_Calculations
folder can be omitted. The following code sample shows how to remove the display
of folders in this example.
String[] paths = {"XADEMO_Measures", "PWD_Calculations/Global_Calculations"}; qb.setItemSearchPaths(paths);
The following list shows how the Items panel will appear based on the methods in this example.
Actual Budget GlobalCalc1 GlobalCalc2 Sales Units Channel Division Geography Product Time
Suppose that you decide that the names of folders in the previous default presentation in the Items panel are rather technical. You decide that your users can benefit by seeing folders with names that are easier to read. The following code sample shows how to rename the folders for display in this example.
String[] paths = {"XADEMO_Measures", "PWD_Calculations/Global_Calculations", "PWD_Calculations/User_Pedro_Calculations"}; String[] pathNames = {"Sales Data", "All Calculations", "Pedro's Calculations"}; qb.setItemSearchPaths(paths); qb.setItemSearchPathNames(pathNames);
The following list shows how the Items panel will appear based on the methods in this example.
All Calculations GlobalCalc1 GlobalCalc2 Pedro's Calculations Calc1 Calc2 Calc3 Sales Data Actual Budget Sales Units Channel Division Geography Product Time
Customizing a QueryBuilder
Customizing QueryBuilder Behavior
Customizing QueryBuilder Panels
Customizing the Components in a QueryBuilder