Hi @Hannah,
1. Create a JSON file using the stored object parameter. Something like this:
{
"Type": "SELECT",
"Tier": "Standard",
"SelectParameters": {
"InputSerialization": {
"CSV": {
"FileHeaderInfo": "USE"
}
},
"ExpressionType": "SQL",
"Expression": "SELECT * FROM object",
"OutputSerialization": {
"CSV": {}
}
},
"OutputLocation": {
"S3": {
"BucketName": "awsexamplebucket",
"Prefix": "outputJob",
"StorageClass": "STANDARD"
}
}
}
2. Run the restore-object command
$ aws s3api restore-object --bucket awsexamplebucket --key file.csv --restore-request file://restoreJob.json
3. You'll get your S3 object location. something like this:
{
"RestoreOutputPath": "outputJob/example_iNHt-0sE2cqt8ZtwNdE1nHi7nKzRaIWLyzzcsW4QWIUaHduHVReDDdavy-aLfEdnD6ql3AR8s4f4oZzhdhBg/"
}