copy data from redshift to s3 code example
Example 1: copy command to load data from s3 to redshift
copy customer
from 's3://mybucket/mydata'
iam_role 'arn:aws:iam::0123456789012:role/MyRedshiftRole';
Example 2: copy table from redshift to s3
UNLOAD ('select * from my_schema.my_table')
to 's3://bucket-name/file_’
iam_role 'arn:aws:iam::482569874589:role/RedshiftLoaderRole’;