Example: Create a Manifest File Using READ_NOS - Teradata VantageCloud Lake

Lake - Manage and Move Data

Deployment
VantageCloud
Edition
Lake
Product
Teradata VantageCloud Lake
Release Number
Published
February 2025
ft:locale
en-US
ft:lastEdition
2025-05-16
dita:mapPath
atx1683670417382.ditamap
dita:ditavalPath
pny1626732985837.ditaval
dita:id
atx1683670417382

If a WRITE_NOS operation fails before being able to create a manifest file you can use READ_NOS with RETURNTYPE('NOSREAD_KEYS') to read the keys of the existing objects in external object storage. This is used as input to create a new manifest file. The new manifest file created this way reflects all data objects currently in the external object storage location, and can aid in determining which data objects resulted from an incomplete WRITE_NOS operation.

  1. Create a manifest file using READ_NOS as input:
    SELECT * FROM WRITE_NOS
    ( ON 
       (SELECT Location, ObjectLength FROM (
           LOCATION='YOUR-OBJECT-STORE-URI/20180627/'
           AUTHORIZATION=MyAuthObj
           RETURNTYPE='NOSREAD_KEYS'
         ) as d1 )
      USING 
        AUTHORIZATION(MyAuthObj)
        MANIFESTFILE('YOUR-OBJECT-STORE-URI/20180627/ManifestFile3/manifest3.json')
        MANIFESTONLY('TRUE')
        OVERWRITE('TRUE')
    ) AS d;

    Replace the LOCATION of YOUR-OBJECT-STORE-URI/20180701/ with the URI to the external object storage location where you want to write the manifest file.

    Replace the MANIFESTFILE location of YOUR-OBJECT-STORE-URI/20180701/ManifestFile3/manifest3.json with the URI to the manifest file on external object storage.

    Your result is similar to the following:

    ObjectName                                                              ObjectSize
    ------------------------------------------------------------------------- ----------
    /S3/s3.amazonaws.com/iewritenostest/20180627/ManifestFile3/manifest3.json        996