16.20 - SET SESSION DOT NOTATION - Teradata Database - Teradata Vantage NewSQL Engine

Teradata Vantage™ SQL Data Definition Language Syntax and Examples

Product
Teradata Database
Teradata Vantage NewSQL Engine
Release Number
16.20
Published
March 2019
Content Type
Programming Reference
Publication ID
B035-1144-162K
Language
English (United States)
Last Update
2019-05-24

Purpose

Sets the session response for dot notation query results that return a list of values.

To specify the system default, use the DBS Control setting, DotNotationOnErrorCondition. See Teradata Vantage™ - Database Utilities , B035-1102 .

Privileges

None.

Syntax



Syntax Elements

DEFAULT
For pre-16.0 dot notation query results that include a list, a warning and an error message appears. Otherwise, the list of values is returned.
LIST
Returns the list of values for dot notation query results that include a list of values.
NULL
Returns null for pre-16.0 dot notation query results.
ERROR
Returns an error for pre-16.0 dot notation query results.

Example: Default Response for 15.0 and 15.10 Dot Notation

The default response for 15.0 and 15.10 is to return an error for dot notation query results that include a list of values.

SET SESSION DOT NOTATION DEFAULT ON ERROR;
SELECT CAST('{"a":1,"a":2}' as JSON).a;
*** Warning: 7548 More than one result per JSON instance found.
> *** ERROR MULTI RESULT **