The problem

The left panel in ClearQuest is very important as it contains a query hierarchy that allows the user finding quickly her project, components she is implicated in, sheets she has to work on, etc.

When data are large and complex, it is very important to systematically organise this hierarchy and to maintain it up to date with newly created items. For example, one folder is created per project at the Public Queries root, then one folder per component inside each project, then eventually one folder per component version and finally a set of queries organised in accordance with the kind and the state of records.

Generally, this manual task is assigned to the administrator, it may take a big amount of time and quickly become tedious.

The solution

The solution consists in maintaining automatically this query hierarchy, from a query template hierarchy, by hooks triggered by key events. Those templates include cookies that will be replaced by values at instantiation time.

Consider the template hierarchy below:

Each time a ProductLine is created, a corresponding folder is created, in which the cookie #PLXXX is replaced by the name of the ProductLine, with associated queries. When a Product is associated to this ProductLine, a sub folder is created, in which the cookie #PYYY is replaced by the name of the Product. Each time a Product version is created, ...

In the example above, three hooks are associated to the three key events (ProductLine creation, Product to ProductLine association, Product version creation) in order to maintain the query hierarchy. For this mechanism to work, any user that may trigger a key event must have the query editor privilege.

Once a query is generated this way, it may be tailored by users as any other query.

Charts are processed the same way with a limitation: cookies cannot be parsed in legend and in axis labels.

This mechanism is complemented by a script that generates in one shot all the query hierarchy on an existing user database. This script can (or not) replace existing queries, allowing upgrading existing queries when templates evolve. This script may also replace the associated set of hooks if it is run regularly.

The offer

This solution is available the following way: the customer sends a dump of her schema along with a sample of the hierarchy of queries and charts to be automated. The updated schema is sent back, with the associated hooks, the template hierarchy of queries/charts and the global script for one-shot queries generation. This offer is limited to Perl language.