Downloading Custom Files

Teradata® Vantage User Guide

brand
Teradata Vantage
prodname
Teradata Vantage
vrm_release
1.0
category
User Guide
featnum
B700-4002-098K

A custom file installed by a function or user can be downloaded from Teradata ML Engine to a local directory on the SQL Engine. The downloaded files can be opened, read, updated, or transferred to other systems like a regular file.

Downloading from Private Schema

You can list all the functions and files that are installed in your private schema by running the HELP FOREIGN SCHEMA command. For example, if you are logged in as alice, run :
help foreign schema alice@coprocessor;
For more information, see Help Foreign Schema Command.
To download an installed file (in this case default_sentiment_lexicon.txt) from your private schema into the local directory of the SQL Engine node:
CALL PM.DOWNLOAD_AFILE('default_sentiment_lexicon.txt');
The file is downloaded into: /opt/teradata/tdqg/connector/tdqg-teradata-connector/UDF/fromAster/user .

Downloading from Public Schema

You can list all the functions and files that are installed on the public schema by running the HELP FOREIGN SCHEMA command. For example:
help foreign schema "public"@coprocessor;
For more information, see Help Foreign Schema Command.
To download an installed file (in this case, default_sentiment_lexicon.txt) from the public schema into the local directory of the SQL Engine node:
CALL PM.DOWNLOAD_AFILE_FROM_PUBLIC('default_sentiment_lexicon.txt');
The file is downloaded into: /opt/teradata/tdqg/connector/tdqg-teradata-connector/UDF/fromAster/user .