edit-icon download-icon

Common errors for log query and analysis

Last Updated: Jul 10, 2018

This document describes the common errors for log query and analysis. For more information about the basic syntaxes, see Syntax description.

List of common errors

  1. line 1:44: Column ‘my_key_field’ cannot be resolved;please add the column in the index attribute
  2. Column ‘xxxx__line__‘ not in GROUP BY clause;please add the column in the index attribute
  3. sql query must follow search query,please read syntex doc
  4. please read syntex document,and make sure all related fields are indexed. error after select .error detail:line 1:10: identifiers must not start with a digit; surround the identifier with double quotes
  5. please read syntex document,and make sure all related fields are indexed. error after select .error detail:line 1:9: extraneous input ‘’ expecting

1. line 1:44: Column ‘my_key_field’ cannot be resolved;please add the column in the index attribute

Error cause: The key my_key_field does not exist. Therefore, you cannot reference the key for query.

Solution: On the query page, add this field as a key/value index and enable the analytics in the index attributes.

2. Column ‘xxxx__line__‘ not in GROUP BY clause;please add the column in the index attribute

Error cause: You use the GROUP BY syntax for query, but a non-agg field which is not contained in GROUP BY is referenced in SELECT. For example, in select key1, avg(latency) group by key2, key1 is not contained in GROUP BY.

Solution: The correct syntax is select key1,avg(latency) group by key1,key2.

3. sql query must follow search query,please read syntex doc

Error cause: The filter condition is not specified. For example, select ip,count(*) group by ip.

Solution: The correct syntax is *|select ip,count(*) group by ip.

4. please read syntex document,and make sure all related fields are indexed. error after select .error detail:line 1:10: identifiers must not start with a digit; surround the identifier with double quotes

Error cause: The column name or variable name referenced in SQL starts with a number, which is not allowed.

Solution: Modify the name to start with a letter.

5. please read syntex document,and make sure all related fields are indexed. error after select .error detail:line 1:9: extraneous input ‘’ expecting

Error cause: The word spelling is incorrect.

Solution: Find the incorrect word spelling according to the location specified in the error and correct the spelling.

Thank you! We've received your feedback.