1 amazon.s3.uploadBlob

Gets the object stored in Amazon S3 under the specified bucket and key. Returns null if the specified constraints weren't met. To get an object from Amazon S3, the caller must have Permission. Read access to the object.

<aamazon.s3.uploadBlob
    bucketName='bucketName'
    fileName='fileName'
    acl='Private|PublicRead|PublicReadWrite|AuthenticatedRead|LogDeliveryWrite|BucketOwnerRead|BucketOwnerFullControl|AwsExecRead'
    multipart='multipart'
    access-key='access-key'
    secret-key='secret-key'
    region='region'
>
    <blob /> +
</aamazon.s3.uploadBlob>
Example
Copy
<xsql-script name='upload_blob_sample'>
    <body>
        <select prefix='m_'>
            <columns>codart, lowres</columns>
            <from table='gartimag'/>
            <where> codart = '026147'  </where>
        </select>
        
        <amazon.s3.uploadBlob bucketName='testjabbucket' acl='PublicReadWrite' fileName='#m_codart' multipart='false' >
            <m_lowres />
        </amazon.s3.uploadBlob>        
        
        <println><amazon.s3.listKeys bucketName='testjabbucket' /></println>
        
        
    </body>
</xsql-script>

Which prints in standard output:

Copy
+-------------------+-------+-------+-----------------------------+------------+--------------------------------+
|key                |owner  |size   |lastModified                 |storageClass|ETag                            |
|char               |char   |long   |char                         |char        |char                            |
|visible            |visible|visible|visible                      |visible     |visible                         |
+-------------------+-------+-------+-----------------------------+------------+--------------------------------+
|026147             |       |   5195|Mon Sep 04 18:06:45 CEST 2017|STANDARD    |464f8a86c0bbcc413ee43bfbe9a4dc5e|
|sample_fil3_s3_name|       |     12|Mon Sep 04 17:58:20 CEST 2017|STANDARD    |2cad20c19a8eb9bb11a9f76527aec9bc|
+-------------------+-------+-------+-----------------------------+------------+--------------------------------+