Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
1964f79
Replace sqlgram links
dveeden May 10, 2024
240deae
Update develop/dev-guide-create-table.md
dveeden May 10, 2024
9b34de6
Update SQL Statement Overview
dveeden May 22, 2024
902fa71
Update for TiDB Cloud
dveeden May 22, 2024
c113006
Apply suggestions from code review
dveeden May 23, 2024
1401d67
Update sql-statements/sql-statement-overview.md
dveeden May 23, 2024
54384fe
Apply suggestions from code review
dveeden May 23, 2024
da0a832
Update sql-statements/sql-statement-overview.md
dveeden May 23, 2024
c29724f
Update sql-statements/sql-statement-overview.md
dveeden May 23, 2024
a1e2e84
Update sql-statements/sql-statement-overview.md
dveeden May 23, 2024
287b4cb
Update sql-statements/sql-statement-overview.md
dveeden May 23, 2024
bd69faa
Update sql-statements/sql-statement-overview.md
dveeden May 23, 2024
3257654
Update sql-statements/sql-statement-overview.md
dveeden May 23, 2024
6977559
Update sql-statements/sql-statement-overview.md
dveeden May 23, 2024
8047f9c
fixup
dveeden May 23, 2024
2f2975f
Apply suggestions from code review
dveeden May 23, 2024
46e4d15
Add links for MySQL compat and monitoring
dveeden May 23, 2024
ecc2909
Update sql-statements/sql-statement-overview.md
dveeden May 23, 2024
f5de44a
Update sql-statements/sql-statement-overview.md
dveeden May 23, 2024
8e3d3a2
Update sql-statements/sql-statement-overview.md
dveeden May 23, 2024
6dede6e
Update sql-statements/sql-statement-overview.md
dveeden May 23, 2024
19146e6
update show profiles
dveeden May 23, 2024
2ba885a
Update monitoring links for cloud
dveeden May 23, 2024
df37799
Update sql-statements/sql-statement-overview.md
dveeden May 24, 2024
81b3f5f
Apply suggestions from code review
dveeden May 24, 2024
e2abe3e
Move ADMIN RECOVER INDEX based on review
dveeden May 24, 2024
1597d9d
Keep all the same sections for tidb-cloud
dveeden May 24, 2024
0e45b88
Update sql-statements/sql-statement-overview.md
dveeden May 24, 2024
87bd887
Update develop/dev-guide-tidb-crud-sql.md
dveeden May 27, 2024
eb5cf34
Apply suggestions from code review
dveeden May 27, 2024
d6a11b5
format udpates
qiancai May 27, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions TOC-tidb-cloud.md
Original file line number Diff line number Diff line change
Expand Up @@ -348,6 +348,7 @@
- [Expression Syntax](/expression-syntax.md)
- [Comment Syntax](/comment-syntax.md)
- SQL Statements
- [Overview](/sql-statements/sql-statement-overview.md)
- [`ADD COLUMN`](/sql-statements/sql-statement-add-column.md)
- [`ADD INDEX`](/sql-statements/sql-statement-add-index.md)
- [`ADMIN`](/sql-statements/sql-statement-admin.md)
Expand Down
1 change: 1 addition & 0 deletions TOC.md
Original file line number Diff line number Diff line change
Expand Up @@ -717,6 +717,7 @@
- [Expression Syntax](/expression-syntax.md)
- [Comment Syntax](/comment-syntax.md)
- SQL Statements
- [Overview](/sql-statements/sql-statement-overview.md)
- [`ADD COLUMN`](/sql-statements/sql-statement-add-column.md)
- [`ADD INDEX`](/sql-statements/sql-statement-add-index.md)
- [`ADMIN`](/sql-statements/sql-statement-admin.md)
Expand Down
2 changes: 1 addition & 1 deletion basic-sql-operations.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ To experiment with SQL and test out TiDB compatibility with MySQL queries, you c

</CustomContent>

This page walks you through the basic TiDB SQL statements such as DDL, DML and CRUD operations. For a complete list of TiDB statements, see [TiDB SQL Syntax Diagram](https://pingcap.github.io/sqlgram/).
This page walks you through the basic TiDB SQL statements such as DDL, DML and CRUD operations. For a complete list of TiDB statements, see [TiDB SQL Syntax](/sql-statements/sql-statement-overview.md)).

## Category

Expand Down
4 changes: 3 additions & 1 deletion develop/dev-guide-create-table.md
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ CREATE TABLE `bookshop`.`ratings` (
);
```

In addition, if the current time is also filled in by default when the data is being updated, the following statements can be used (but only the [current time related statements](https://pingcap.github.io/sqlgram/#NowSymOptionFraction) can be filled in after `ON UPDATE`, and [more options](https://pingcap.github.io/sqlgram/#DefaultValueExpr) are supported after `DEFAULT`):
In addition, if the current time is also filled in by default when the data is being updated, the following statements can be used (but only the current-time related expressions can be filled in after `ON UPDATE`):

```sql
CREATE TABLE `bookshop`.`ratings` (
Expand All @@ -195,6 +195,8 @@ CREATE TABLE `bookshop`.`ratings` (
);
```

For more information on default values of different data types, see [default values](/data-type-default-values.md).

### Prevent duplicate values

If you need to prevent duplicate values in a column, you can use the `UNIQUE` constraint.
Expand Down
4 changes: 2 additions & 2 deletions develop/dev-guide-tidb-crud-sql.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ TiDB is compatible with MySQL, you can use MySQL statements directly in most cas

To experiment with SQL and test out TiDB compatibility with MySQL queries, you can try [TiDB Playground](https://play.tidbcloud.com/?utm_source=docs&utm_medium=basic-sql-operations). You can also first deploy a TiDB cluster and then run SQL statements in it.

This page walks you through the basic TiDB SQL statements such as DDL, DML, and CRUD operations. For a complete list of TiDB statements, see [TiDB SQL Syntax Diagram](https://pingcap.github.io/sqlgram/).
This page walks you through the basic TiDB SQL statements such as DDL, DML, and CRUD operations. For a complete list of TiDB statements, see [SQL Statement Overview](/sql-statements/sql-statement-overview.md).

## Category

Expand All @@ -35,7 +35,7 @@ SQL is divided into the following 4 types according to their functions:

- **DCL (Data Control Language)**: It is used to define access privileges and security levels.

The following mainly introduces DML and DQL. For more information about DDL and DCL, see [Explore SQL with TiDB](/basic-sql-operations.md) or [TiDB SQL syntax detailed explanation](https://pingcap.github.io/sqlgram/).
The following mainly introduces DML and DQL. For more information about DDL and DCL, see [Explore SQL with TiDB](/basic-sql-operations.md) or [SQL Statement Overview](/sql-statements/sql-statement-overview.md).

## Data Manipulation Language

Expand Down
2 changes: 1 addition & 1 deletion expression-syntax.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ The expressions can be divided into the following types:

- ParamMarker (`?`), system variables, user variables and CASE expressions.

The following rules are the expression syntax, which is based on the [`parser.y`](https://github.com/pingcap/tidb/blob/master/pkg/parser/parser.y) rules of TiDB parser. For the navigable version of the following syntax diagram, refer to [TiDB SQL Syntax Diagram](https://pingcap.github.io/sqlgram/#Expression).
The following rules are the expression syntax, which is based on the [`parser.y`](https://github.com/pingcap/tidb/blob/master/pkg/parser/parser.y) rules of TiDB parser.

```ebnf+diagram
Expression ::=
Expand Down
4 changes: 1 addition & 3 deletions mysql-compatibility.md
Original file line number Diff line number Diff line change
Expand Up @@ -158,9 +158,7 @@ For more information, refer to [Understand the Query Execution Plan](/explain-ov

### Built-in functions

TiDB supports most of the built-in functions in MySQL, but not all. You can use the statement `SHOW BUILTINS` to get a list of the available functions.

For more information, refer to the [TiDB SQL Grammar](https://pingcap.github.io/sqlgram/#functioncallkeyword).
TiDB supports most of the built-in functions in MySQL, but not all. You can use the statement [`SHOW BUILTINS`](/sql-statements/sql-statement-show-builtins.md) to get a list of the available functions.

### DDL operations

Expand Down
Loading