Skip to content

update_column_statistics_task_settings async

update_column_statistics_task_settings(
    database_name: NameString,
    table_name: NameString,
    *,
    config_overrides: Optional[AsyncGlueClientConfig] = None,
    role: Optional[NameString] = None,
    schedule: Optional[CronExpression] = None,
    column_name_list: Optional[ColumnNameList] = None,
    sample_size: Optional[SampleSizePercentage] = None,
    catalog_id: Optional[CatalogIdString] = None,
    security_configuration: Optional[NameString] = None,
) -> UpdateColumnStatisticsTaskSettingsResponse

Updates settings for a column statistics task.

Parameters:

  • database_name (NameString) –

    The name of the database where the table resides.

  • table_name (NameString) –

    The name of the table for which to generate column statistics.

  • role (Optional[NameString], default: None ) –

    The role used for running the column statistics.

  • schedule (Optional[CronExpression], default: None ) –

    A schedule for running the column statistics, specified in CRON syntax.

  • column_name_list (Optional[ColumnNameList], default: None ) –

    A list of column names for which to run statistics.

  • sample_size (Optional[SampleSizePercentage], default: None ) –

    The percentage of data to sample.

  • catalog_id (Optional[CatalogIdString], default: None ) –

    The ID of the Data Catalog in which the database resides.

  • security_configuration (Optional[NameString], default: None ) –

    Name of the security configuration that is used to encrypt CloudWatch logs.

Raises:

Source code in docs_src/capo_glue/_services/async_glue.py
async def update_column_statistics_task_settings(
    self,
    database_name: "capo_glue.types.name_string.NameString",
    table_name: "capo_glue.types.name_string.NameString",
    *,
    config_overrides: Optional[AsyncGlueClientConfig] = None,
    role: Optional["capo_glue.types.name_string.NameString"] = None,
    schedule: Optional["capo_glue.types.cron_expression.CronExpression"] = None,
    column_name_list: Optional[
        "capo_glue.types.column_name_list.ColumnNameList"
    ] = None,
    sample_size: Optional[
        "capo_glue.types.sample_size_percentage.SampleSizePercentage"
    ] = None,
    catalog_id: Optional[
        "capo_glue.types.catalog_id_string.CatalogIdString"
    ] = None,
    security_configuration: Optional[
        "capo_glue.types.name_string.NameString"
    ] = None,
) -> "capo_glue.types.update_column_statistics_task_settings_response.UpdateColumnStatisticsTaskSettingsResponse":
    """<p>Updates settings for a column statistics task.</p>

    Args:
        database_name: <p>The name of the database where the table resides.</p>
        table_name: <p>The name of the table for which to generate column statistics.</p>
        role: <p>The role used for running the column statistics.</p>
        schedule: <p>A schedule for running the column statistics, specified in CRON syntax.</p>
        column_name_list: <p>A list of column names for which to run statistics.</p>
        sample_size: <p>The percentage of data to sample.</p>
        catalog_id: <p>The ID of the Data Catalog in which the database resides.</p>
        security_configuration: <p>Name of the security configuration that is used to encrypt CloudWatch logs.</p>

    Raises:
        capo_glue.errors.access_denied_exception.AccessDeniedException: <p>Access to a resource was denied.</p>
        capo_glue.errors.entity_not_found_exception.EntityNotFoundException: <p>A specified entity does not exist</p>
        capo_glue.errors.invalid_input_exception.InvalidInputException: <p>The input provided was not valid.</p>
        capo_glue.errors.operation_timeout_exception.OperationTimeoutException: <p>The operation timed out.</p>
        capo_glue.errors.version_mismatch_exception.VersionMismatchException: <p>There was a version conflict.</p>
        capo_glue.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_glue.types.update_column_statistics_task_settings_request.UpdateColumnStatisticsTaskSettingsRequest]",
    ) -> AsyncOperationResponse[
        "capo_glue.types.update_column_statistics_task_settings_response.UpdateColumnStatisticsTaskSettingsResponse"
    ]:
        import capo_glue._operations.aws_glue.update_column_statistics_task_settings

        (
            output,
            http_response,
        ) = await capo_glue._operations.aws_glue.update_column_statistics_task_settings.async_update_column_statistics_task_settings(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("UpdateColumnStatisticsTaskSettings")
    )
    input_: capo_glue.types.update_column_statistics_task_settings_request.UpdateColumnStatisticsTaskSettingsRequest = {
        "database_name": database_name,
        "table_name": table_name,
    }
    if role is not None:
        input_["role"] = role
    if schedule is not None:
        input_["schedule"] = schedule
    if column_name_list is not None:
        input_["column_name_list"] = column_name_list
    if sample_size is not None:
        input_["sample_size"] = sample_size
    if catalog_id is not None:
        input_["catalog_id"] = catalog_id
    if security_configuration is not None:
        input_["security_configuration"] = security_configuration

    response = await aexecute_pipeline(
        AsyncOperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    await response.response.aclose()
    return response.output