Type

class aws_cdk.aws_glue.Type(*args: Any, **kwargs)

Bases: object

The type of a column in a table schema.

Instances are opaque: obtain one from a Schema factory (for example Schema.STRING, Schema.decimal(...), Schema.array(...)) or, for a type the Schema factories don’t model, from Schema.custom(...).

ExampleMetadata:

infused

Example:

# my_database: glue.Database

glue.S3Table(self, "MyTable",
    database=my_database,
    columns=[glue.Column(
        name="data",
        type=glue.Schema.STRING
    )],
    partition_keys=[glue.Column(
        name="date",
        type=glue.Schema.STRING
    )],
    data_format=glue.DataFormat.JSON,
    partition_projection={
        "date": glue.PartitionProjectionConfiguration.date(
            min="NOW-3YEARS",
            max="NOW",
            format="yyyy-MM-dd"
        )
    }
)

Attributes

input_string

Glue InputString for this type.

is_primitive

Indicates whether this type is a primitive data type.