Teradata Package for Python Function Reference on VantageCloud Lake | 17.20 - translate - Teradata Package for Python - Look here for syntax, methods and examples for the functions included in the Teradata Package for Python.

Teradata® Package for Python Function Reference on VantageCloud Lake

Deployment
VantageCloud
Edition
Lake
Product
Teradata Package for Python
Release Number
17.20
Publication Date
November 2022
Content Type
Programming Reference
Publication ID
B700-4500-112K
ft:locale
en-US
ft:lastEdition
2024-02-21
ft:sourceId
FTML
dita:id
TeradataPython_FxRef_Lake_1720
Product Category
Teradata Vantage
teradataml.dataframe.sql_functions.translate = translate(x, source='UNICODE', target='LATIN')
Returns a TRANSLATE(x USING source_TO_target) expression
 
PARAMETERS:
  x: A ColumnExpression instance coming from the DataFrame
     or output of other functions in sql_functions. A python
     string literal may also be used.
 
  source, target: str with values:
    - 'UNICODE'
    - 'LATIN'
 
REFERENCES:
  Chapter 28: String Operators and Functions
  Teradata® Database SQL Functions, Operators, Expressions, and
  Predicates, Release 16.20
 
EXAMPLES:
  >>> from teradataml.dataframe.sql_functions import translate
 
  >>> df = DataFrame('df')
  >>> tvshow = df['tvshow']
 
  >>> res = df.assign(tvshow = translate(tvshow))