Skip to content

Commit

Permalink
docs: add sql syntax description 'SHOW COLUMNS FROM [DB.]TABLE'
Browse files Browse the repository at this point in the history
  • Loading branch information
hustjieke authored and BohuTANG committed Sep 3, 2018
1 parent af431e4 commit 001bb14
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions docs/radon_sql_support.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ Contents
* [SHOW ENGINES](#show-engines)
* [SHOW DATABASES](#show-databases)
* [SHOW TABLES](#show-tables)
* [SHOW COLUMNS](#show-columns)
* [SHOW CREATE TABLE](#show-create-table)
* [SHOW PROCESSLIST](#show-processlist)
* [SHOW VARIABLES](#show-variables)
Expand Down Expand Up @@ -658,6 +659,34 @@ mysql> SHOW TABLES;
2 rows in set (0.01 sec)
```

### SHOW COLUMNS

`Syntax`

```
SHOW COLUMNS FROM [db_name.]table_name
```

`Instructions`
* Get the column definitions of a table

`Example: `

```
mysql> CREATE TABLE T1(A INT, B VARCHAR(10)) PARTITION BY HASH(A);
Query OK, 0 rows affected (0.52 sec)
mysql> SHOW COLUMNS FROM T1;
+-------+-------------+------+-----+---------+-------+
| Field | Type | Null | Key | Default | Extra |
+-------+-------------+------+-----+---------+-------+
| A | int(11) | YES | | NULL | |
| B | varchar(10) | YES | | NULL | |
+-------+-------------+------+-----+---------+-------+
2 rows in set (0.01 sec)
```

### SHOW CREATE TABLE

`Syntax`
Expand Down

0 comments on commit 001bb14

Please sign in to comment.