Sample CMDB queries Use the following sample queries to build your own CMDB queries. CMDB query sample Use this example to build a CMDB query. All servers with a connection to a database Navigate to Configuration and click CMDB Query Builder Click Create new. Enter a Name - All servers with a connection to a DB. Choose CMDB Query, and click Create. In the CMDB Artifacts list, locate the Server class, and drag it to the canvas. Locate the Database class, and place it to the right of the Server class node on the canvas. Click at the center of the right side of Server, and then at the center of the left side of Database to create a connection. In the Connection Properties dialog, in the Add Relations for Server 1 section – one by one, select all the listed relationships. Note that the added relationships are displayed in the navigation bar on the right, underneath Server 1. Click Save, and then click Saved Queries on the left to see the tile for the saved query. Click the query tile to return to the canvas in edit mode. Click Run to execute the query.Review the query results. Each row displays the name of a server CI, the name of a database CI, and the relationship type between them. Add columns to the query results: Click Server 1 on the canvas. On the right navigation bar, underneath Server 1 Report Columns, click Add Columns. Select Manufacturer. Click Run.Review the query results which now include the Manufacturer column. Click Save again to save all your customization for this query. Service Mapping query sample Use this example to build a Service Mapping query. Linux server in services Note: To build and run a Service Mapping query, Service Mapping must be activated. Navigate to Configuration and click CMDB Query Builder Click Create new. Enter a Name - Linux server in services. Choose Service Mapping Query, and click Create. In the CMDB Artifacts, locate Linux Server, and drag it to the canvas. Click Run.Review the query results. Each row displays the name of a Service Mapping Service and the name of a Linux Server that is a member of that service. On the right navigation bar, click Disable Service Including This Pattern, and then click Run again. Review the query results. Now, each row displays the name a Service Mapping Service that does not include the specified Linux Server.