Queries

Queries is a standard configuration interface for adding, editing, and removing stored queries from Unified Assurance.

Refer to the Standard Configuration Interface guide for details on interacting with the grid and form. The additional control is explained in the Grid Details section.

This user interface calls REST methods from api/database/queries.

The UI path for this interface is Configuration -> Databases -> Queries.

Grid Details

The interface displays the standard Unified Assurance buttons as well as the following:

Form Fields

Query Toolbar

Best Practices

Token Value Replacement Example

  1. Create a database query named Devices in Zone with placeholders.

    • Query Name => Devices in Zone

    • Schema => Assure1

    • ShardID => 1

    • Query User Owner => [Public to All Users In Group]

    • Query Group Owner => [Public to All Groups]

    • Query

      SELECT DeviceID,
             DeviceName,
             INET_NTOA(IPAddress)    AS IPAddress,
             INET6_NTOA(IPv6Address) AS IPv6Address
        FROM Devices 
       WHERE DeviceZoneID = ? 
      
    • Tokens => Click the "Add" button, then set the following:

      Token Default Value
      Zone 1
    • Click on the "Submit" button.

  2. Go to the Dashboards UI.

    Configuration -> Dashboards -> Dashboards

  3. Click the Add button, then set the following:

    • Name => Devices in Zone
  4. Add a "database -> Database Grid" panel to the dashboard.

  5. Click the "Configure Panel" button, then set the following:

    • Panel Name => Device List in Zone

    • Query => Devices in Zone

    • Click on the "View" button.

  6. Click on the "Submit" button.

    Note:

    The following reserved words cannot be used as values:

    • DashboardID

    • QueryID

    • Tokens

    • page

    • start

    • limit

  7. Open a new browser tab and enter the URL below, replacing the placeholders:

    https://((PRESENTATION_SERVER))/#dashboard/Devices in Zone?Zone=((DEVICE_ZONE))
    
    ----- EXAMPLE -----
    
    https://unified-assurance.example.com/#dashboard/Devices in Zone?Zone=3
    

    The dashboard will open and use the value from the URL instead of the default token value.