Comment on page
Amazon S3
This article describes how to create a connection to Amazon S3 using a SQL command.
To read from and write to your Amazon S3 buckets in SQLake, you must first create a connection that provides the appropriate credentials to access your buckets.
Note that when you integrate Upsolver with your AWS account, there is an S3 connection created by default, but you may still want to create your own connection for specific access configurations.
CREATE S3 CONNECTION
<connection_identifier>
[{ AWS_ROLE = '<role_arn>'
EXTERNAL_ID = '<external_id>'
| AWS_ACCESS_KEY_ID = '<key_id>'
AWS_SECRET_ACCESS_KEY = '<key>' }]
[ PATH_DISPLAY_FILTER[S] = { '<path>' | ('<path>' [, ...]) } ]
[ READ_ONLY = { TRUE | FALSE } ]
[{ ENCRYPTION_KMS_KEY = '<key>' ]
| ENCRYPTION_CUSTOMER_MANAGED_KEY = '<key>' }]
[ COMMENT = '<comment>' ];
Type:
text
If omitted, the role created when integrating Upsolver with the AWS account is used.
Type:
text
If omitted, the role created when integrating Upsolver with the AWS account is used.
Type:
text
If omitted, the role created when integrating Upsolver with the AWS account is used.
Type:
text
If omitted, the role created when integrating Upsolver with the AWS account is used.
Type:
text | list
(Optional) A single path or the list of paths to show. If not provided, all buckets are shown.
Paths should be provided in the following format:
s3://bucket/prefix
. This shows anything beginning with the given prefix.To filter by a specific folder, use the following format:
s3://bucket/folder-path/
Type:
boolean
Default:
false
(Optional) Whether or not the connection is read-only.
When
true
, Upsolver is not able to write data to or delete data from, the bucket.Type:
text
(Optional) The ARN of the KMS key to use.
If omitted, uses the default encryption defined on the bucket in AWS.
Type:
text
(Optional) The Base64 text representation of the encryption key to use.
If omitted, uses the default encryption defined on the bucket in AWS.
Type:
text
(Optional) A description or comment regarding this connection.
CREATE S3 CONNECTION my_s3_connection;
This example uses the default credentials from Upsolver's integration with AWS.
CREATE S3 CONNECTION s3_example
AWS_ROLE = 'arn:aws:iam::123456789012:role/upsolver-sqlake-role'
PATH_DISPLAY_FILTERS = ('s3://bucket1/', 's3://bucket2/folder-path/')
READ_ONLY = TRUE
ENCRYPTION_KMS_KEY = 'arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab'
COMMENT = 'My new S3 connection';
Last modified 1mo ago