Skip to content

Latest commit

 

History

History
37 lines (21 loc) · 1.71 KB

expression-syntax.md

File metadata and controls

37 lines (21 loc) · 1.71 KB
title summary aliases
Expression Syntax
Learn about the expression syntax in TiDB.
/docs/dev/expression-syntax/
/docs/dev/reference/sql/language-structure/expression-syntax/

Expression Syntax

An expression is a combination of one or more values, operators, or functions. In TiDB, expressions are mainly used in various clauses of the SELECT statement, including Group by clause, Where clause, Having clause, Join condition and window function. In addition, some DDL statements also use expressions, such as the setting of the default values, columns, and partition rules when creating tables.

The expressions can be divided into the following types:

The following rules are the expression syntax, which is based on the parser.y rules of TiDB parser. For the navigable version of the following syntax diagram, refer to TiDB SQL Syntax Diagram.

Expression:

Expression

PredicateExpr:

PredicateExpr

BitExpr:

BitExpr

SimpleExpr:

SimpleExpr