Administer > Database Administration > Data persistence > Queries > Create a query using more than one field

Create a query using more than one field

Applies to User Roles:

System Administrator

Example: Retrieve all device records where the logical.name field in the Manage CIs form begins with the letter H and the IP address field starts with 196.76.209.

In this example, we perform a search on the Location and IP Address fields in the device form and return a list of device records matching these criteria. Database Manager forms record list queries on scalar, or non-arrayed fields, with the and logical operator. Searches are case-sensitive, unless you first set up your database for case-insensitive searching.

To create a query using more than one field:

  1. Click Tailoring > Database Manager.
  2. Type =device in the Form field, and then click Search.
  3. On the Search Configuration Records form, do the following:
    • Type H in the Location field.
    • Select the Advanced Filter tab, and then click Add New Filter Criteria.

      The Add Filter Criteria wizard opens.

    • In the Field in Configuration Item field, select the IP Address field.
    • In the Comparison field select Starts With.
    • In the Value field, type 196.76.209.
    • Click Next.

      You are returned to the Search Configuration Records form.

  4. Open the More Actions menu and choose Expert Search.

    You will see your query in the Query field.

  5. Click Search.

    When a partially keyed query is executed, HPE Service Manager searches the file for a specified time interval, or until the screen buffer is filled. When either threshold is met, it stops and displays the records retrieved up until that point.

    A warning then displays, indicating an attempt to initiate a partially keyed query. If you receive a warning message of this type, you have limitations in your operator or user profile that prevent the execution of inefficient queries.

  6. Add a time interval to your query, and then click Search to execute the query again.
  7. Click any record in the list of returned records to view the details.

Note: A device is also referred to as a Configuration Item (CI).