Skip to content

Creates a new table definition in the Data Catalog

Description

Creates a new table definition in the Data Catalog.

Usage

glue_create_table(CatalogId, DatabaseName, Name, TableInput,
  PartitionIndexes, TransactionId, OpenTableFormatInput)

Arguments

  • CatalogId

    The ID of the Data Catalog in which to create the Table. If none is supplied, the Amazon Web Services account ID is used by default.

  • DatabaseName

    [required] The catalog database in which to create the new table. For Hive compatibility, this name is entirely lowercase.

  • Name

    The unique identifier for the table within the specified database that will be created in the Glue Data Catalog.

  • TableInput

    The TableInput object that defines the metadata table to create in the catalog.

  • PartitionIndexes

    A list of partition indexes, PartitionIndex structures, to create in the table.

  • TransactionId

    The ID of the transaction.

  • OpenTableFormatInput

    Specifies an OpenTableFormatInput structure when creating an open format table.

Value

An empty list.

Request syntax

svc$create_table(
  CatalogId = "string",
  DatabaseName = "string",
  Name = "string",
  TableInput = list(
    Name = "string",
    Description = "string",
    Owner = "string",
    LastAccessTime = as.POSIXct(
      "2015-01-01"
    ),
    LastAnalyzedTime = as.POSIXct(
      "2015-01-01"
    ),
    Retention = 123,
    StorageDescriptor = list(
      Columns = list(
        list(
          Name = "string",
          Type = "string",
          Comment = "string",
          Parameters = list(
            "string"
          )
        )
      ),
      Location = "string",
      AdditionalLocations = list(
        "string"
      ),
      InputFormat = "string",
      OutputFormat = "string",
      Compressed = TRUE|FALSE,
      NumberOfBuckets = 123,
      SerdeInfo = list(
        Name = "string",
        SerializationLibrary = "string",
        Parameters = list(
          "string"
        )
      ),
      BucketColumns = list(
        "string"
      ),
      SortColumns = list(
        list(
          Column = "string",
          SortOrder = 123
        )
      ),
      Parameters = list(
        "string"
      ),
      SkewedInfo = list(
        SkewedColumnNames = list(
          "string"
        ),
        SkewedColumnValues = list(
          "string"
        ),
        SkewedColumnValueLocationMaps = list(
          "string"
        )
      ),
      StoredAsSubDirectories = TRUE|FALSE,
      SchemaReference = list(
        SchemaId = list(
          SchemaArn = "string",
          SchemaName = "string",
          RegistryName = "string"
        ),
        SchemaVersionId = "string",
        SchemaVersionNumber = 123
      )
    ),
    PartitionKeys = list(
      list(
        Name = "string",
        Type = "string",
        Comment = "string",
        Parameters = list(
          "string"
        )
      )
    ),
    ViewOriginalText = "string",
    ViewExpandedText = "string",
    TableType = "string",
    Parameters = list(
      "string"
    ),
    TargetTable = list(
      CatalogId = "string",
      DatabaseName = "string",
      Name = "string",
      Region = "string"
    ),
    FederatedTable = list(
      Identifier = "string",
      DatabaseIdentifier = "string",
      ConnectionName = "string",
      ConnectionType = "string"
    ),
    ViewDefinition = list(
      IsProtected = TRUE|FALSE,
      IsManaged = TRUE|FALSE,
      Definer = "string",
      Representations = list(
        list(
          Dialect = "REDSHIFT"|"ATHENA"|"SPARK",
          DialectVersion = "string",
          ViewOriginalText = "string",
          ValidationConnection = "string",
          ViewExpandedText = "string"
        )
      ),
      ViewVersionId = 123,
      ViewVersionToken = "string",
      RefreshSeconds = 123,
      LastRefreshType = "FULL"|"INCREMENTAL",
      SubObjects = list(
        "string"
      ),
      SubObjectVersionIds = list(
        123
      ),
      SubObjectsStatistics = list(
        list(
          SourceType = "HIVE_PARQUET"|"HIVE_ORC"|"HIVE_CSV"|"HIVE_JSON"|"PLAIN_PARQUET"|"ICEBERG",
          GlueVersionId = "string",
          PartitionCount = 123,
          FileCount = 123,
          TotalFileBytes = 123
        )
      ),
      SparkPipelineInfo = list(
        "string"
      )
    )
  ),
  PartitionIndexes = list(
    list(
      Keys = list(
        "string"
      ),
      IndexName = "string"
    )
  ),
  TransactionId = "string",
  OpenTableFormatInput = list(
    IcebergInput = list(
      MetadataOperation = "CREATE",
      Version = "string",
      CreateIcebergTableInput = list(
        Location = "string",
        Schema = list(
          SchemaId = 123,
          IdentifierFieldIds = list(
            123
          ),
          Type = "struct",
          Fields = list(
            list(
              Id = 123,
              Name = "string",
              Type = list(),
              Required = TRUE|FALSE,
              Doc = "string",
              InitialDefault = list(),
              WriteDefault = list()
            )
          )
        ),
        PartitionSpec = list(
          Fields = list(
            list(
              SourceId = 123,
              Transform = "string",
              Name = "string",
              FieldId = 123
            )
          ),
          SpecId = 123
        ),
        WriteOrder = list(
          OrderId = 123,
          Fields = list(
            list(
              SourceId = 123,
              Transform = "string",
              Direction = "asc"|"desc",
              NullOrder = "nulls-first"|"nulls-last"
            )
          )
        ),
        Properties = list(
          "string"
        )
      )
    )
  )
)