Custom query problems in the Data Management Portal

This information covers common problems that occur with the custom query in the TADDM Data Management Portal.

Cannot run queries with Mac OS, IBM i, and Tru64 computer system classes

Problem
You cannot run queries with Mac OS, IBM® i, and Tru64 computer system classes (for example, Tru64.guid is-not-null). You can recognize a broken query because after the query is run, the Result Attributes field is empty.
Solution
Perform one of the following actions:
  • Use the custom query function in the Discovery Management Console.
  • Explicitly select required columns in the query using the Result Attributes window.

Query that includes units does not return expected results

Problem
A custom query that includes criteria specifying units (for example, 4000 MHz) does not return the expected results.
Solution
Units are not stored in the database. Instead, all attribute values are stored in the database with units converted to a least common denominator; for example, the value 4000 MHz is stored as 4000000000 Hz. To return these values, a query must specify the value in the same terms used to store it.

The unit used in the database varies depending upon the type of value. To determine the unit for a particular attribute, you can run a test query on that attribute to see how the values are stored. You can then calculate the correct values for your custom query by converting to the appropriate units.

Custom query cannot handle array attributes

Problem
The Custom Query function in the Data Management Portal has a limitation in that the attributes that are selected as part of the query cannot be array attributes (for example, ipInterfaces).

This occurs because the query engine that is called by the Custom Query UI does not support the parsing of attributes that are arrays.

The attributes that are included in the custom query are checked and if any of the attributes are arrays, the following error message is displayed:
Custom Query does not currently support attributes which are arrays, such as {0}.
Solution
Use the api.sh script, which returns all available data for the object that is selected, instead of using the Data Management Portal to run a custom query.

For more information on how to use the api.sh function, see the TADDM SDK Developer's Guide.