You can view query signatures from the Presto Utilization dashboard and use the query signatures to identify and group similar queries.
The Presto Utilization dashboard is available upon request for most customers.
Presto query signatures are clusters of Presto queries share common SQL statements. Similar jobs, jobs with only a few differences (such as the date range computed), are grouped together. You can then analyze the clusters of queries and determine which queries require the most or least resources in a given month.
The Presto Query Details table, which is posted on the Presto Utilization dashboard, includes a table column: Query Names or Signature.
Query Signature Definitions for Common Letters
The following list defines common query letters that help to decipher the query that the query signature represents:
- S: Select
- S[* ] means SELECT * is used (retrieving all columns. This argument might be inefficient because our storage is columnar format.)
- Cnt: count(x)
- CntD: count(distinct x) (If query has this signature, it means a single node process = slow!)
- T: table
- G: Group by
- J: Join
- O: Order by (single node process = slow!)
- L: Limit
- CT: Create table
- I: Insert Into
- DT: Delete table
- D: Delete
- E: Duplicate Elimination (select distinct, union, etc.)
- U: Union All
- E(U(…)): Union (with duplicate elimination)
|Query Signatures are subject to change.|
The following example shows SQL statements mapped to query signatures:
select 1 S(V) select * from t S[*](T) t-># insert into A select * from B I(S[*](T)) B->A select * from t, 'query' S[*](T) select * from t, 'table' t->#