Overview
Advanced queries allow you to query your resource configuration states for one or more regions using ResourceQL.
You can conveniently use ResourceQL and a query editor to search for and view your resources.
ResourceQL is a subset of structured query language (SQL) SELECT syntax to help you perform property-based queries and aggregations. The query complexity varies. You can query resources by tag or resource identifier, or by using complex SQL statements. For example, you can query an ECS with a specified OS version.
You can use Advanced Queries to:
- Manage inventory: For example, query ECSs that meet specific criteria.
- Audit security compliance: For example, query resources to check if specific attributes, such as EIPs or encrypted disks, are enabled or disabled.
- Optimize costs: For example, list all unattached EVS disks to prevent unnecessary costs.
Advanced queries rely on resource data captured by the resource recorder. It is highly recommended to maintain an enabled status for the recorder. Query availability and results are governed by the following recorder states:
- Inactive state: If the resource recorder has never been enabled, advanced queries return no data.
- Partial scope: If the monitoring scope is restricted to a subset of resources, advanced queries only return data for those selected resources.
- Discontinuation: If the recorder is disabled after being active, advanced queries only retrieve historical data captured during its active duration.
For details about how to enable and configure the resource recorder, see Configuring the Resource Recorder.
Features
- Flexible query condition configuration
Advanced search enables you to customize criteria based on service requirements to locate resources precisely. Combining multiple filter criteria allows you to quickly narrow the search scope and filter target resources accurately. This feature supports basic queries and complex scenarios, such as associated resource and multi-condition queries, ensuring you obtain accurate results for in-depth data analysis.
- Multi-dimensional resource query
Advanced search allows you to flexibly specify the query scope. You can query resources from a specific cloud service or across multiple cloud services and regions.
- Query template management
To simplify operations, advanced search provides preset templates containing common query statements to help you quickly locate target resources. Additionally, you can save custom query statements as personal templates for future reuse. This feature improves efficiency and ensures consistent query behavior, helping users with varying levels of experience quickly and accurately obtain resource information.
Notes and Constraints
To prevent a single user from occupying resources for a long time, the advanced query function is restricted as follows:
- If the execution duration of a query statement exceeds 15 seconds, a timeout error will be returned.
- If the result set is too large, an error will occur. Make sure that the data volume returned by each statement is within the size limit.
- The system only returns up to 4,000 records for a single query.
- A single query statement can execute no more than two join queries.
- Each account can perform a maximum of 200 advanced queries.
Use advanced queries to retrieve, view, and export cloud service resource data. To modify or delete a resource, navigate to the specific service console where the resource is hosted.
What is your overall rating for this page?
Thank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot