String Functions | DataFrame Column | Teradata Package for Python - String Functions - Teradata Package for Python

Teradata® Package for Python User Guide

Deployment
VantageCloud
VantageCore
Edition
Enterprise
IntelliFlex
VMware
Product
Teradata Package for Python
Release Number
20.00
Published
March 2024
Language
English (United States)
Last Update
2024-04-09
dita:mapPath
nvi1706202040305.ditamap
dita:ditavalPath
plt1683835213376.ditaval
dita:id
rkb1531260709148
Product Category
Teradata Vantage

teradataml DataFrameColumn supports following set of string functions.

See the String Functions section of Teradata Package for Python Function Reference, B700-4008) at https://docs.teradata.com/ for detailed description and usage examples of these functions.

String Functions supported by DataFrameColumn
Sr. No. Function Name Description
1 concat() Function to concatenate the columns with a separator.
2 like() Function to match the string pattern. String match is case sensitive.
3 ilike() Function to match the string pattern. String match is not case sensitive.
4 substr() Returns the substring from a string column.
5 startswitch() Function to check if the column value starts with the specified value or not.
6 endswitch() Function to check if the column value ends with the specified value or not.
7 format() Function to format the values in column based on formatter.
8 to_char() Function converts numeric type or datetype to character type.
9 trim() Function trims the string values in the column.
10 ascii() Returns the decimal representation of the first character in column.
11 char2hexint() Returns the hexadecimal representation for a character string in a column.
12 chr() Returns the Latin ASCII character of a given a numeric code value in column.
13 char() It is an alias for chr() function.
14 character_length() Returns the number of characters in the column.
15 char_length() It is an alias for character_length() function.
16 edit_distance() Returns the minimum number of edit operations required to transform string in a column into string specified in argument.
17 index() Returns the position of a string in a column where string specified in argument starts.
18 initcap() Modifies a string column and returns the string with the first character of each word in uppercase.
19 instr() Searches the string in a column for occurrences of search string passed as argument.
20 lcase() Returns a character string identical to string values in column, with all uppercase letters replaced with their lowercase equivalents.
21 left() Truncates string in a column to a specified number of characters desired from the left side of the string.
22 length() It is an alias for character_length() function.
23 levenshtein() It is an alias for edit_distance() function.
24 locate() Returns the position of the first occurrence of a string in a column within string in argument.
25 lower() It is an alias for character_lcase() function.
26 lpad() Returns the string in a column padded to the left with the characters specified in argument so that the resulting string has length specified in argument.
27 ltrim() Returns the string in a column, with its left most characters removed up to the first character that is not in the string specified in argument.
28 ngram() Returns the number of n gram matches between string in a column, and string specified in argument.
29 nvp() Extracts the value of a name value pair where the name in the pair matches the name and the number of the occurrence specified.
30 oreplace() Replaces every occurrence of search string in the column.
31 otranslate() Returns string in a column with every occurrence of each character in string in argument replaced with the corresponding character in another argument.
32 replace() It is an alias for oreplace() function.
33 reverse() Returns the reverse of string in column.
34 right() Truncates input string to a specified number of characters desired from the right side of the string.
35 rpad() Returns the string in a column padded to the right with the characters specified in argument so the resulting string has length specified in argument.
36 rtrim() Returns the string in column, with its right most characters removed up to the first character that is not in the string specified in argument.
37 soundex() Returns a character string that represents the Soundex code for string in a column.
38 string_cs() Returns a heuristically derived integer value that can be used to determine which KANJI1 compatible client character set was used to encode string in a column.
39 translate() It is an alias for otranslate() function.
40 upper() Returns a character string with all lowercase letters in a column replaced with their uppercase equivalents.