IQA Queries: Best practices when using and testing queries

Review the following before beginning to create your own IQA queries.

In This Article 

Test the query

Tip! It is always a recommended best practice to test as you build a new query.

  • Test your query as you add sources and relations. If you are building a query with multiple sources, it is advised that you test (Run tab) as you add sources.
  • Note: It is recommended to start building your query with two sources only.

  • Test with sample filter values to determine how long the query takes. If results take more than a few seconds, reconsider adding that query to a control on a page. Every time the page loads, that wait time on the query becomes a cost.
  • As you test, you can rebuild your query as performance dictates. It might be necessary to rebuild poorly performing queries.
  • If you do not see any data, or the data you see is not useful, modify the returned display. Click the Display tab to change the results, then run the query again.
  • Note: Do not use queries that take greater than five seconds to return results. Queries that run for greater than five seconds are indicative of a poorly written query that could affect performance.

Reviewing the queries that are shipped with iMIS

iMIS ships a number of queries you can use as examples to emulate or as starting points from which you can create your own queries. For example, select a query at $/Samples/Dashboards. You can open the query to review how it was created, how relations were defined, and how filters were applied.

Consider reviewing the Samples query folder ($/Samples) at RiSE > Intelligent Query Architect. You can also review existing queries for specific modules in iMIS.

You can build your own query to match, or you can Save As and edit a copy of the out-of-the-box query.

You can also use Easy Edit to review queries on other pages in iMIS. Simply enable Easy Edit, then review the content to locate the Source query on the content item.

Using the Query Menu content item

Use “Show initial results for queries with optional filters” only for fast-running queries

This option can slow the page load time if the source query takes a long time to return results.

Use “Reload list from database” only when needed

This option ensures that fresh data is retrieved each time the page is refreshed, so it should only be enabled if up-to-date data is important for the content’s purpose. If Use cache results is enabled in your query, this option does not apply and so should not be enabled.

Use a lower number of results per page to improve page load time

The Results to display per page option can affect the time required to load the page; a value of 25 or less is recommended.

Use Required prompts in queries that are displayed using the Query Menu content item

Using Required filters (or the Require user to provide at least one valid value option) as opposed to Optional filters ensures that the user cannot request all results, but must filter the request to a subset of results. This can improve the response time of the query because fewer rows will be returned.

Use the RiSE dashboard if you cannot locate a query

The RiSE dashboard provides a search feature to easily determine where a query is located.

Do the following to search for a query:

  1. Go to RiSE > Dashboard.
  2. Click the Queries tab.
  3. From the Select a query drop-down, leave List of queries selected.
  4. Use the search filters to locate the query:
    1. Query contains - Enter the name or partial name of the query.
    2. Is system - Choose Any, Yes, or No:
      • Any - Returns out-of-the-box and custom queries.
      • Yes - Returns only out-of-the-box queries.
      • No - Returns only custom queries.
  5. Click Find. The search results display the following information:
    • Query - The name of the query and a link to open the query for editing.
    • Path - Where the query is located in the Document System.
    • Access Setting - Who can access the query.
    • Updated On - The last time the query was updated.

Import error: Document Already Exists in a Different Path

The following error may appear when attempting to import a query: Error: Document Already Exists in a Different Path. Use CreateCopy or CreateShortcut to import.

This error occurs when attempting to import a document into iMIS, but an existing document with the same DocumentKey is already stored in a different path within the system. Because each document must have a unique DocumentKey, iMIS prevents duplicate entries.

Tip! To find a query, use the search feature on the RiSE dashboard. See Searching for queries.

To successfully import the document, do the following:

  1. In the original system where the document exists, create a copy (Organize > Copy) of the content.
  2. Export the copied content.
  3. From the system you are importing into, import the newly created copy.