Important
The SingleStore 9.1 release candidate (RC) is available now. It will be promoted to general availability (GA) soon and at that time it will be renamed to SingleStore 10.
In the interim, SingleStore 9.1 RC can be used to preview, evaluate, and provide feedback on the new and upcoming features in SingleStore 10, while SingleStore 9.0 is recommended for production workloads.
SHOW COLUMNS
On this page
The SHOW COLUMNS command shows the list of columns within a given table.
Syntax
SHOW [FULL] COLUMNS {FROM | IN} tbl_name [{FROM | IN} db_name] [LIKE 'pattern' | WHERE expr]Remarks
-
LIKE'pattern' can be used to filter the list by name.SQL LIKE clause. -
This command must be run on the Master Aggregator or a child aggregator node (see Node Requirements for SingleStore Commands).
-
See the Permission Matrix for the required permission.
Output
|
Column |
Description |
|---|---|
|
|
Field name |
|
| |
|
|
Whether this column allows nulls |
|
|
An attribute or attributes that uniquely identify table rows. |
|
|
Default value, if applicable |
|
|
Additional information |
Example
SHOW COLUMNS IN mytbl;+----------+------------+------+-----+---------+-------+| Field | Type | Null | Key | Default | Extra |+----------+------------+------+-----+---------+-------+| seq | int(11) | YES | MUL | NULL | || state | int(11) | YES | | NULL | || st_case | varchar(8) | YES | | NULL | || veh_no | varchar(2) | YES | | NULL | || drimpair | varchar(2) | YES | | NULL | |+----------+------------+------+-----+---------+-------+5 rows in set (0.00 sec)
Last modified: