Working with Saved Viewpoint Queries
Copying Viewpoint Queries
You can copy public queries, and any private queries that you created. When you copy a query, it is saved as a private query. Data Managers and Metadata Managers can promote it to public.
To copy a query:
- In the Query Panel, click Actions
, and then select Copy.
- Enter a name, and optionally a description, and then click
Save.
Note:
The Visibility field indicates that the query is saved as a private query. If you have Data Manager or Metadata Manager permission on the viewpoint you can promote it to a public query.
Inspecting Viewpoint Queries
Inspecting a viewpoint query enables you to view the query definition and parameters, and to change the query name and description. You can also assign a code to the query to use instead of the query name when automating the query via the REST API.
To inspect a query:
- From an open viewpoint: Click Query Viewpoint
to display the list of saved queries for that viewpoint. Then, click the Query action menu
next to the query that you want to inspect and select Inspect.
- From an open Query in a viewpoint: Click the Query action menu
next to the Run button, and then select Inspect.
- From the Viewpoint inspector:
- Inspect the viewpoint that contains the query. See Inspecting a Viewpoint.
- On the Queries tab, click the name of the query that you want to inspect.
To edit the query name and description, or to assign a code to the query:
- On the General tab of the query inspector, click Edit.
- Edit the name and description.
- In the Code field, enter a code for the query.
The code that you enter can be used in the
queryCode
parameter in the Run a Viewpoint Query Profile REST API instead of thequeryName
to identify the query in the API. This allows the query name to be changed without any effect to automated processes. - Click Save.
Promoting Viewpoint Queries
You must have Data Manager or Metadata Manager permission on the viewpoint in order to promote a query.
To promote a query:
- Perform an action:
- From an open viewpoint, click Query Viewpoint
to display the list of saved queries for that viewpoint.
- Inspect the viewpoint that contains the query that you want to promote. See Inspecting a Viewpoint.
- From an open viewpoint, click Query Viewpoint
- Click Action
next to the query that you want to promote, and then select Promote.
- Click Save.
Note:
If the query that you promote has the same name as an existing public query, an incrementing numeric suffix is appended to the query to make it unique.
Deleting Viewpoint Queries
You can delete your private queries from the Query panel or the viewpoint inspector. If you have Data Manager or Metadata Manager permission on the viewpoint, you can delete public queries as well.
To delete a query:
- From the Query panel in a viewpoint: From the list of queries in the
Query panel, click the Query action menu
next to the query that you want to delete, and then select Delete.
Tip:
If you already have a query open and you want to go back to the query list, click the Query Viewpointtab to return to the list of saved queries.
- From the Viewpoint inspector:
- Inspect the viewpoint that contains the query that you want to delete. See Inspecting a Viewpoint.
- Click Action
next to the query that you want to delete, and then select Delete.
- Click Save.