awswrangler.athena.get_query_executions

awswrangler.athena.get_query_executions(query_execution_ids: list[str], return_unprocessed: bool = False, boto3_session: Session | None = None) tuple[DataFrame, DataFrame] | DataFrame

From specified query execution IDs, return a DataFrame of query execution details.

https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/athena.html#Athena.Client.batch_get_query_execution

Parameters:
  • query_execution_ids (List[str]) – Athena query execution IDs.

  • return_unprocessed (bool.) – True to also return query executions id that are unable to be processed. False to only return DataFrame of query execution details. Default is False

  • boto3_session (boto3.Session(), optional) – Boto3 Session. The default boto3 session will be used if boto3_session receive None.

Returns:

  • DataFrame – DataFrame contain information about query execution details.

  • DataFrame – DataFrame contain information about unprocessed query execution ids.

Examples

>>> import awswrangler as wr
>>> query_executions_df, unprocessed_query_executions_df = wr.athena.get_query_executions(
        query_execution_ids=['query-execution-id','query-execution-id1']
    )