See If the JSON Object Has a Header Row | Native Object Store | Teradata Vantage - Previewing Data Using READ_NOS - Advanced SQL Engine - Teradata Database

Teradata Vantageā„¢ - Native Object Store Getting Started Guide

Product
Advanced SQL Engine
Teradata Database
Release Number
17.05
Published
January 2021
Language
English (United States)
Last Update
2021-01-22
dita:mapPath
zws1595641486108.ditamap
dita:ditavalPath
hoy1596145193032.ditaval
dita:id
B035-1214
lifecycle
previous
Product Category
Software
Teradata Vantage

To understand the contents of external data, sample some rows using the READ_NOS table operator.

The examples and results show a sample river flow data set. To use your own data, replace the table and column names, and authorization object.

  1. To run NOS-related commands, log on to the database as a user with the required privileges.
  2. Run the following SQL example:
    SELECT TOP 2 payload FROM READ_NOS_FM (
    ON ( SELECT CAST(NULL AS JSON) )
    USING
    LOCATION('YOUR-STORAGE-ACCOUNT')
    RETURNTYPE('NOSREAD_RECORD')
    ) AS D;

    See Variable Substitutions for Examples for the credentials and location values for the sample river flow data set.

    Result:

    Payload
    --------------------------------------------------------------------
    { "site_no":"09380000", "datetime":"2018-07-03 00:00", "Flow":"17600", "GageHeight":"10.23", "Temp":"10.6", "Conductance"
    { "site_no":"09380000", "datetime":"2018-06-29 00:00", "Flow":"15700", "GageHeight":"9.87", "Temp":"10.6", "Conductance"

    Note, the payload column is truncated in the result.