All Products
Search
Document Center

PolarDB:ALL_TAB_COLS

Last Updated:Sep 13, 2024

You can view all the tables, views, and specific columns that are accessible to the current account by using the ALL_TAB_COLS view.

Note

The ALL_TAB_COLS view provides the same information as the ALL_TAB_COLUMNS view.

  • You can query ALL_TAB_COLS views of only PolarDB clusters of version 1.1.7 or later. For more information about how to view the edition of a PolarDB cluster, see Release notes.

  • You can query ALL_TAB_COLUMNS views of PolarDB clusters of version 1.1.7 or earlier. For more information about ALL_TAB_COLUMNS views, see ALL_TAB_COLUMNS.

Parameter

Type

Description

owner

CHARACTER VARYING

The username of the owner of a table or view.

schema_name

CHARACTER VARYING

The name of the schema to which the table or the view belongs.

table_name

CHARACTER VARYING

The name of the table or view.

column_name

CHARACTER VARYING

The name of the column.

data_type

CHARACTER VARYING

The data type of the column.

data_length

NUMERIC

The maximum length of data in a column. Unit: characters.

data_precision

NUMERIC

The precision of NUMBER columns. The precision is measured by the number of digits.

data_scale

NUMERIC

The scale of NUMBER columns.

nullable

CHARACTER(1)

Specifies whether the column can have a null value. Valid values:

  • Y: indicates that the column can be null.

  • N: indicates that the column cannot be null.

column_id

NUMERIC

The relative position of the column within the table or view.

data_default

CHARACTER VARYING

The default value for the column.

default_length

INTEGER

The default length of the column.

data_type_owner

TEXT

The owner of the data type of the column.

char_length

NUMERIC

The character length of the column. This parameter is applicable only to data of the character type.

data_semantics

TEXT

The data modifier.