You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by "ASF subversion and git services (JIRA)" <ji...@apache.org> on 2017/04/25 09:32:04 UTC

[jira] [Commented] (AIRFLOW-1119) Redshift to S3 operator - headers not on first row

    [ https://issues.apache.org/jira/browse/AIRFLOW-1119?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15982633#comment-15982633 ] 

ASF subversion and git services commented on AIRFLOW-1119:
----------------------------------------------------------

Commit 4147d6b8091309cbf373d8f24d40da2e4b549473 in incubator-airflow's branch refs/heads/master from Thomas Hofer
[ https://git-wip-us.apache.org/repos/asf?p=incubator-airflow.git;h=4147d6b ]

[AIRFLOW-1119] Fix unload query so headers are on first row[]

Closes #2245 from th11/airflow-1119-fix


> Redshift to S3 operator - headers not on first row
> --------------------------------------------------
>
>                 Key: AIRFLOW-1119
>                 URL: https://issues.apache.org/jira/browse/AIRFLOW-1119
>             Project: Apache Airflow
>          Issue Type: Bug
>            Reporter: Thomas H
>             Fix For: 1.8.2
>
>         Attachments: airflow-bug.png
>
>
> The RedshiftToS3 operator adds headers when unloading data from redshift to s3. However, there is a bug where the headers can appear in any row (see screenshot). Need to add `ORDER BY 1 DESC` to the query below to ensure headers are on first row.
> https://github.com/apache/incubator-airflow/blob/master/airflow/operators/redshift_to_s3_operator.py#L93:L102
> More info regarding unloading data with headers:
> http://stackoverflow.com/questions/24681214/unloading-from-redshift-to-s3-with-headers
> https://medium.com/carwow-product-engineering/unloading-a-file-from-redshift-to-s3-with-headers-fb707f5480f7



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)