Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

Querying for asset types

Is it possible to query for asset types, so that only a subset of the asset types in RAM are returned?

0 votes



4 answers

Permanent link
There is not a documented or supported method to perform such a query. You may use the facets on the search page to see all assets in a single type. However, there is an unsupported way perform the query.

For example, if you wanted to query for all assets in
'type1' or 'type2' or 'Type Three'

The query would be
fType:(type1) OR fType(type2) OR fType(type_three)

Notice for 'Type Three' that it is necessary to lowercase all letters and replace spaces with underscores.

0 votes


Permanent link
Is there a supported or not-supported way to search for assets that are NOT of a certain type?

0 votes


Permanent link
To find all assets not in 'type1' the query would be
* !fType:(type1)

To find all assets not in 'Type Three' the query would be
* !fType(type_three)

0 votes


Permanent link
In the spirit of sharing here is my search code using the API to find assets modified in a week timeframe that were NOT of type General Documentation:

RAMAssetQueryBuilder queryBuilder = new RAMAssetQueryBuilder(session);
queryBuilder.setMaxResults(-1);
String query = "_lastModified_:() AND !fType:(general_documentation)";
SearchResult pagedResult = session.getAssets(queryBuilder);

0 votes

Your answer

Register or log in to post your answer.

Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details

Question asked: Dec 01 '10, 12:37 p.m.

Question was seen: 4,560 times

Last updated: Dec 01 '10, 12:37 p.m.

Confirmation Cancel Confirm