Exasol to Amazon S3¶
Use the ExasolToS3Operator transfer to export data from an Exasol database
table or query result into an Amazon Simple Storage Service (S3) file.
Prerequisite Tasks¶
To use these operators, you must do a few things:
Create necessary resources using AWS Console or AWS CLI.
Install API libraries via pip.
pip install 'apache-airflow[amazon]'Detailed information is available Installation of Airflow®
Operators¶
Exasol To Amazon S3 transfer operator¶
This operator exports data from an Exasol database to an Amazon S3 file.
It uses the export_to_file method of the underlying
pyexasol connection to export the data to a local
temporary file, and then uploads the file to S3 with the
S3Hook.
Use the query_or_table parameter to export either the result of a SQL query or a whole table.
Extra parameters can be passed to the underlying export method with query_params and
export_params.
To get more information about this operator visit:
ExasolToS3Operator
Example usage:
exasol_to_s3_job = ExasolToS3Operator(
task_id="exasol_to_s3_job",
query_or_table=exasol_table,
key=s3_key,
bucket_name=s3_bucket,
replace=True,
)