Information Schema
The StarRocks Information Schema is a database within each StarRocks instance. Information Schema contains several read-only, system-defined views that store extensive metadata information of all objects that the StarRocks instance maintains. The StarRocks Information Schema is based on the SQL-92 ANSI Information Schema, but with the addition of views and functions that are specific to StarRocks.
From v3.2.0, The StarRocks Information Schema supports manage metadata for external catalogs.
View metadata via Information Schemaโ
You can view the metadata information within a StarRocks instance by querying the content of views in Information Schema.
The following example checks metadata information about a table named table1 in StarRocks by querying the view tables.
MySQL > SELECT * FROM information_schema.tables WHERE TABLE_NAME like 'table1'\G
*************************** 1. row ***************************
TABLE_CATALOG: def
TABLE_SCHEMA: test_db
TABLE_NAME: table1
TABLE_TYPE: BASE TABLE
ENGINE: StarRocks
VERSION: NULL
ROW_FORMAT:
TABLE_ROWS: 4
AVG_ROW_LENGTH: 1657
DATA_LENGTH: 6630
MAX_DATA_LENGTH: NULL
INDEX_LENGTH: NULL
DATA_FREE: NULL
AUTO_INCREMENT: NULL
CREATE_TIME: 2023-06-13 11:37:00
UPDATE_TIME: 2023-06-13 11:38:06
CHECK_TIME: NULL
TABLE_COLLATION: utf8_general_ci
CHECKSUM: NULL
CREATE_OPTIONS:
TABLE_COMMENT:
1 row in set (0.01 sec)
Views in Information Schemaโ
The StarRocks Information Schema contains the following metadata views:
analyze_status
analyze_status provides information about the status of analyze jobs.
applicable_roles
applicable_roles provides information about roles that are applicable to the current user.
be_bvars
be_bvars provides statistical information regarding bRPC.
be_cloud_native_compactions
be_cloud_native_compactions provides information on compaction transactions running on CNs (or BEs for v3.0) of a shared-data cluster.
be_compactions
be_compactions provides statistical information on compaction tasks.
be_configs
be_configs provides information about the configuration parameters of each BE node.
be_logs
be_logs provides information about the logs of each BE node.
be_metrics
be_metrics provides information about the metrics of each BE node.
be_tablets
be_tablets provides information about tablets on each BE node.
be_threads
be_threads provides information about the threads running on each BE node.
be_txns
be_txns provides information about transactions on each BE node.
character_sets
character_sets identifies the character sets available.
collations
collations contains the available collations.
column_privileges
Information schema placeholder view not implemented in StarRocks.
column_stats_usage
column_stats_usage provides information about the usage of column statistics.
columns
columns contains information about all table columns (or view columns).
engines
Information schema placeholder view not implemented in StarRocks.
events
Information schema placeholder view not implemented in StarRocks.
fe_metrics
fe_metrics provides information about the metrics of each FE node.
fe_tablet_schedules
fe_tablet_schedules provides information about tablet scheduling tasks on FE nodes.
fe_threads
fe_threads provides information about the threads running on each FE node.
global_variables
global_variables provides information about global variables.
key_column_usage
Information schema placeholder view not implemented in StarRocks.
load_tracking_logs
load_tracking_logs provides error logs of load jobs.
loads
loads provides the results of load jobs.
materialized_view_refresh_jobs
materialized_view_refresh_jobs provides job-level information about materialized view refreshes.
materialized_views
materialized_views provides information about all materialized views.
partitions
Information schema placeholder view not implemented in StarRocks.
partitions_meta
partitions_meta provides information about partitions of tables.
pipe_files
pipe_files provides the status of the data files to be loaded via a specified pipe.
pipes
pipes provides information about all pipes stored in the current or specified database.
recyclebin_catalogs
recyclebin_catalogs provides metadata information of deleted databases, tables, and partitions temporarily stored in the FE recycle bin.
referential_constraints
Information schema placeholder view not implemented in StarRocks.
routine_load_jobs
routine_load_jobs provides information about routine load jobs.
routines
Information schema placeholder view not implemented in StarRocks.
schema_privileges
Information schema placeholder view not implemented in StarRocks.
schemata
schemata provides information about databases.
session_variables
session_variables provides information about session variables.
statistics
Information schema placeholder view not implemented in StarRocks.
stream_loads
stream_loads provides information about stream load jobs.
table_constraints
Information schema placeholder view not implemented in StarRocks.
table_privileges
Information schema placeholder view not implemented in StarRocks.
tables
tables provides information about tables.
tables_config
tables_config provides information about the configuration of tables.
task_runs
task_runs provides information about the execution of asynchronous tasks.
tasks
tasks provides information about asynchronous tasks.
triggers
Information schema placeholder view not implemented in StarRocks.
user_privileges
Information schema placeholder view not implemented in StarRocks.
verbose_session_variables
verbose_session_variables provides session variable details including default values and whether they have been modified.
views
views provides information about all user-defined views.
warehouse_metrics
warehouse_metrics provides information about the metrics of each warehouse.
warehouse_queries
warehouse_queries provides information about queries running on each warehouse.