Queries
- Last UpdatedJul 31, 2024
- 2 minute read
AVEVA Events to CONNECT queries are configured to specify data you want to filter from the different type of queries in the on-premises REST API. You can create different queries to filter the data from an on-premises REST API.
Configure AVEVA Events to CONNECT Queries using Curl commands
Complete the following steps to configure AVEVA Events to CONNECT Queries. Use the PUT method in conjunction with the api/v1/configuration/<ComponentId>/Queries REST endpoint to initialize the configuration.
-
Use a text editor to create an empty text file.
-
Copy and paste an example configuration for an AVEVA Events to CONNECT Queries into the file. For sample JSON, see Queries example.
-
Update the example JSON parameters for your environment. For a table of all available parameters, see Queries parameters.
-
Save the file. For example, as ConfigureQueries.json.
-
Open a command line session. Change directory to the location of ConfigureQueries.json.
-
Enter the following curl command (which uses the PUT method) to initialize the Queries configuration.
curl.exe --ntlm --negotiate -u <UserName> -d "@ConfigureQueries.json" -H "Content-Type: application/json" -X PUT http://localhost:5590/api/v1/configuration/EventsToCONNECTComponent1/Queries
Notes:
If you installed the agent to listen on a non-default port, update 5590 to the port number in use.
If you use a component ID other than EventsToCONNECTComponent1, update the endpoint with your chosen component ID.
For a list of other REST operations you can perform, like updating or deleting a Resource configuration, see Queries REST URLs.
Configure AVEVA Events to CONNECT Queries using the Configurator plugin
Query strings can be added, edited, or deleted in the Data Ingress Queries tab for the selected component.

Create a new query string
To add a query:
-
Select Add.
This is appended to Data source endpoint and resource path for the agent to start collecting event data.
-
Enter a value for the Query String. For more information on input field, see Queries parameters.
Note: It is recommended that placeholders ?ST? and ?ET? are used in the query strings. These will be replaced by start time and end time based on the scheduled run for the agent to fetch event data in a particular period.
Modify a query string
To modify a query:
-
Select an existing item in the Queries list.
-
Update the Query String. Query Id will be read-only once it has been created.
Delete a query string
To delete a query:
-
Select an existing item in the Queries list.
-
Select Delete.
If the Query Id is being used in a data selection item, a validation error will be displayed.