Skip to content

Table

laktory.models.resources.databricks.Table ¤

Bases: BaseModel, PulumiResource, TerraformResource

A table resides in the third layer of Unity Catalog’s three-level namespace. It contains rows of data.

ATTRIBUTE DESCRIPTION
catalog_name

Name of the catalog storing the table

TYPE: Union[str, None]

columns

List of columns stored in the table

TYPE: Union[list[Column], None]

comment

Text description of the catalog

TYPE: Union[str, None]

data_source_format

External tables are supported in multiple data source formats. The string constants identifying these formats are DELTA, CSV, JSON, AVRO, PARQUET, ORC, TEXT. Change forces creation of a new resource. Not supported for MANAGED tables or VIEW.

TYPE: str

grants

List of grants operating on the schema

TYPE: list[TableGrant]

lookup_existing

Specifications for looking up existing resource. Other attributes will be ignored.

TYPE: TableLookup

name

Name of the table

TYPE: str

primary_key

Name of the column storing a unique identifier for each row. It is used by the builder to drop duplicated rows.

TYPE: Union[str, None]

schema_name

Name of the schema storing the table

TYPE: Union[str, None]

storage_credential_name

For EXTERNAL Tables only: the name of storage credential to use. Change forces creation of a new resource.

TYPE: Union[str, None]

storage_location

URL of storage location for Table data (required for EXTERNAL Tables). Not supported for VIEW or MANAGED table_type.

TYPE: Union[str, None]

table_type

Distinguishes a view vs. managed/external Table.

TYPE: Literal['MANAGED', 'EXTERNAL', 'VIEW']

view_definition

SQL text defining the view (for table_type == "VIEW"). Not supported for MANAGED or EXTERNAL table_type.

TYPE: Union[str, None]

warehouse_id

All table CRUD operations must be executed on a running cluster or SQL warehouse. If a warehouse_id is specified, that SQL warehouse will be used to execute SQL commands to manage this table.

TYPE: Union[str, None]

Examples:

from laktory import models

table = models.resources.databricks.Table(
    name="slv_stock_prices",
)
References

Attributes¤

parent_full_name property ¤

parent_full_name

Schema full name {catalog_name}.{schema_name}

full_name property ¤

full_name

Table full name {catalog_name}.{schema_name}.{table_name}

column_names property ¤

column_names

List of column names

is_from_cdc property ¤

is_from_cdc

If True CDC source is used to build the table

resource_key property ¤

resource_key

Table full name (catalog.schema.table)

additional_core_resources property ¤

additional_core_resources
  • table grants

--

laktory.models.resources.databricks.table.TableLookup ¤

Bases: ResourceLookup

ATTRIBUTE DESCRIPTION
name

Full name of the databricks_table: catalog.schema.table

TYPE: str