7.00.02 - CREATE Privileges - Aster Analytics

Teradata Aster® Analytics Foundation User GuideUpdate 2

Product
Aster Analytics
Release Number
7.00.02
Release Date
September 2017
Content Type
Programming Reference
User Guide
Publication ID
B700-1022-700K
Language
English (United States)

Before you run SQL-MapReduce functions, verify that you have the appropriate CREATE privileges on the PUBLIC schema. This helps avoid permission issues in cases where you need CREATE privileges on the PUBLIC schema.

For example, suppose that you run this example code without CREATE privileges on the PUBLIC schema:

SELECT * FROM TextClassifierTrainer (
  ON (SELECT 1) PARTITION BY 1
  InputTable ('s_mktg.bdulay_search_train')
  TextColumn ('s_term')
  CategoryColumn ('s_cat')
  ModelFile ('knn.bin')
  ClassifierType ('knn')
  ClassifierParameters ('compress:0.8')
  NLPParameters ('useStem:true')
  Database ('beehive')
  UserID ('loadusr')
  Password ('loadusr')
);

Because no schema was specified in the argument ModelFile, the function selects the first schema from your search path and tries to install the model file on it. By default, the first schema in the search path is the schema PUBLIC. Because you do not have CREATE privileges on the schema PUBLIC, a privilege failure occurs:

ERROR: SQL-MR function TEXTCLASSIFIERTRAINER failed: Error occurred when install model file: Fail to install file: /tmp/1379088204401/knn.bin
Message:[AsterData][NClusterJDBCDSII](34) ERROR: permission denied for schema "public" for user "loadusr