PlantSight Help

Queries

Used to query model and equipment data using default queries or user defined queries that you can share with team members. Queries created here can be edited, exported, and reimported using the Query Builder.

Layout and Settings

Queries consists of a Queries panel (left side) listing all available queries, a set of Default Queries, a Query Builder, and an Advanced Mode for manually entering queries. Queries created with the Query Builder can be saved and shared with others involved in the project.

SettingDescription
Query panel toolbar Used to manage queries. Located at the top of the queries panel.

Toolbar: Delete Query, Rename Query and Promote to Shared Queries

SettingDescription
Delete Query Removes the selected query.
Rename Query Renames the selected query.
Promote to Shared Queries Adds the selected query to the Shared Queries folder where it can be viewed by all project members.
Note: Default queries can not be deleted, renamed or promoted.
My Queries Lists your user defined queries. Selecting them updates the query panel. Queries in this folder can be promoted to the Shared Queries folder.
Shared Queries Lists queries shared among the project. Selecting them updates the query panel. Queries in this folder are intended to be viewed by all project participants.
Default Queries PlantSight provides predefined queries such as Equipment List and Instrument List as well as an All Data query. Selecting them updates the query panel. The Query Builder can then be used to filter the results.
Query Builder Located above the query table, the Query Builder is used to create queries from the loaded data. Clicking on the Query Builder expand its settings.
Search Class Sets the object class to search for in the query.
Where Clause When on, you can filter the results of the query with the Where Cause settings. Use the three fields to set the where clauses. Clicking the plus sign (+) adds another where clause statement to the query. The trash can icon removes the statement. And/Or operators are used to connect the where clause statements. Where clauses are resolved chronologically.
Query Builder toolbar

Toolbar: Save Query, Save Query As, Run Query

SettingDescription
Save Saves the where clause. A Save dialog opens where you can enter a name for the query.
Save As Saves the where clause as another query. A Save As dialog opens where you can enter a name for the query.
Run Query Press to apply query settings to the data.
Advanced Mode When on, the Query Builder controls are removed from the interface, and a text field is provided for you to enter query statements manually.
In this example, text entered into the field:

select DISTINCT pn.CodeValue as Pipeline_Tag, pn.PLANT_AREA, pn.DESIGN_SIZE, ps.FROM_COMPONENT, ps.TO_COMPONENT from ProcessFunctional.PIPING_NETWORK_SYSTEM pn INNER JOIN ProcessFunctional.PIPING_NETWORK_SEGMENT ps on pn.EcInstanceID=ps.Parent.id WHERE (FROM_COMPONENT <> '' OR TO_COMPONENT <> '')

Yields results which are displayed in the Query Results table. The table can be exported to Excel by clicking the "Export" icon in the toolbar (under "Records count").
Query results toolbar Used to manipulate the search results.

Toolbar: Edit, Import from Excel, Export to Excel, Column Options

SettingDescription
Edit The first tool in the results toolbar above the results table, Edit (pencil). Click to enable editing in the results table. When editing is enabled, the tool bar above the results table changes, adding Save and Cancel buttons.
Import from Excel The next tool in the results toolbar, Import from Excel (X with clockwise arrow). Click to import query data from an Excel file.
Export to Excel The next tool in the results toolbar, Export to Excel (X with counter clockwise arrow). Click to export the query to an Excel file.
Column Options The next tool in the results toolbar, Column Options (3 vertical bars). Clicking opens the Column Options pop up dialog.
  • Drag to rearrange - Clicking on a column entry changes the pointer to a move style allowing you to click and drack the columns to change their arrangement on the results table.
  • Hide column - Click the X button next to the column name to turn off the display of the column in the results table.
  • Read Only/Editable - Click the "eye" icon to make the content displayed in the column read only, or click the "pencil" icon to make the content editable.
  • Save - Click to save the column options for the current query.
  • Default - Click to save the column options as the default for all queries.
  • Cancel - Click to discard the column option changes and close the dialog.