Skip to main content Link Menu Expand (external link) Document Search Copy Copied

SHOW COLUMNS statement

BNF diagram

expr

Syntax

SHOW COLUMNS FROM table_name;

Arguments

Argument Description
table_name name of existing table in database

Returns

Column name Data type Description Additional information
name string column name  
type string column data type Data types
created_at timestamp timestamp TIMESTAMP() data type
keys bool Indicates true if key translation is performed for a column. This is only for STRING and STRINGSET types  
cache_type string    
cache_size int    
scale int Scale value for DECIMAL() column DECIMAL() data type
min int Minimum value for INT() column INT() data type
max int Maximum value for INT() column INT() data type
timeunit string TIMEUNIT for TIMESTAMP() column TIMESTAMP() data type
epoch int Epoch for TIMESTAMP() column TIMESTAMP() data type
time_quantum string Applies to IDSETQ() and STRINGSETQ() columns IDSETQ() data type
STRINGSETQ() data type
ttl string Applies to IDSETQ() and STRINGSETQ() columns IDSETQ() data type
STRINGSETQ() data type

Examples

SHOW COLUMNS on sample database skills table

SHOW COLUMNS FROM skills;
_id name type created_at keys cache_type cache_size scale min max timeunit epoch timequantum ttl  
_id _id string string 2023-01-05T05:53:06Z true   0 0 0 0   0   0s
bools bools stringset 2023-01-05T05:53:06Z true ranked 50000 0 0 0   0   0s  
bools-exists bools-exists stringset 2023-01-05T05:53:06Z true ranked 50000 0 0 0   0   0s  
id id int int 2023-01-05T05:53:06Z false   0 0 -9223372036854776000 9223372036854776000   0   0s
skills skills stringset 2023-01-05T05:53:06Z true ranked 50000 0 0 0   0   0s  
titles titles stringset 2023-01-05T05:53:06Z true ranked 50000 0 0 0   0   0s