Skip to main content

Create an AQS data source

How to create an AQS data source

An AQS data source represents the results of an AQS query that fetches attribute data from items of a particular design/interface.

It can be thought of as a standard table, with each row being an item fetched by the query, and the selected attributes as column headers.

Note

We recommend using the Data Explorer to test out potential AQS queries, so you can see what the data source may look like when the report is run!

Create an AQS data source

To create an AQS data source in the Report Builder:

  1. Open the Data sources tab and select Create data source.
alt text
  1. Supply a meaningful Name. Users will see this when running the report, so ensure it describes the data source clearly. To ensure the data source can't be left empty, enable Required.

  2. Select Type and choose AQS.

alt text
  1. Fill in the remaining form fields:

    • Design or interface - choose the design/interface that the data source will query.

    • Attributes - use the Pathfinder to select the attributes on the chosen design/interface that you want to fetch data for.

    • Default AQS query - we recommend setting an appropriate default query if possible, to safeguard your report against possible failure. Users can change it beforehand if they wish! Select the field to open the AQS Builder.

    • Tags - if your report is ever run from another AQS query (e.g. via a workflow), it's possible for the data source to be automatically populated with that same AQS query. To do this, select the Incoming AQS query tag.

      Details
      alt text
  2. Select Create to finish.

alt text

Customise sorting and headers

If you edit the data source after it's been created, there will be two more optional fields to configure:

Using another data source as a query parameter

It's possible to use another data source in the report as a parameter when setting the Default AQS query.

For example, you want an AQS data source that fetches all items of the Bollards design with an Installed Date later than a user-supplied value.

To do this:

  1. Create a constant data source and set the Type appropriately (e.g. Date time).

  2. When creating your AQS data source, select Default AQS query to show the AQS Builder.

  3. In the blue Parameters box (top-left), select .

alt text
  1. Select Data source headers, select beside your constant data source, and then select the Value header.
alt text
  1. If desired, change the Display name or set a Default value, and then select Save.
alt text
  1. Use the parameter when building your query.
alt text