2.10 - getDatasetFromSql - Teradata QueryGrid

Teradata® QueryGrid™ Installation and User Guide

prodname
Teradata QueryGrid
vrm_release
2.10
created_date
September 2019
category
Administration
Configuration
Installation
User Guide
featnum
B035-5991-099K

Use the getDataSetFromSql() method to perform a lazy execution of a SELECT query involving non-native tables. For example:

scala> ForeignServer.getDatasetFromSql("select * from default.nn1")
res0: org.apache.spark.sql.Dataset[org.apache.spark.sql.Row] = [number: int, name: string]

The query result DataSet (res0 in the above example) is used like any other Spark SQL DataSet object and is only evaluated when an action is called.