String & Binary Functions

This family of functions perform operations on a string input value or binary input value (for certain functions) and return a string or numeric value.

The functions are grouped by type of operation performed:

  • General string operations (matching, padding, trimming, etc.).
  • Encoding and decoding strings using Base64 or Hexadecimal.
  • Using hash functions (MD5) or cryptographic functions (SHA1 or SHA2) to encrypt/encode strings.
Sub-category Function Binary Input Supported Notes
General ASCII    
BIT_LENGTH  
CHARINDEX Alias for POSITION.
CHR , CHAR    
CONCAT , ||  
CONTAINS  
EDITDISTANCE    
ENDSWITH  
ILIKE   Case-insensitive alternative for LIKE.
INITCAP    
INSERT  
LEFT  
LENGTH  
LIKE   Case-sensitive alternative for ILIKE.
LOWER    
LPAD  
LTRIM    
OCTET_LENGTH  
PARSE_URL    
POSITION  
REPEAT    
REPLACE    
REVERSE  
RIGHT  
RPAD  
RTRIM    
RTRIMMED_LENGTH    
SPACE    
SPLIT    
SPLIT_PART    
STARTSWITH  
SUBSTR , SUBSTRING  
TRANSLATE    
TRIM    
UPPER    
UUID_STRING    
Encode/Decode BASE64_DECODE_BINARY    
BASE64_DECODE_STRING    
BASE64_ENCODE  
HEX_DECODE_BINARY    
HEX_DECODE_STRING    
HEX_ENCODE  
TRY_BASE64_DECODE_BINARY   Error-handling version of BASE64_DECODE_BINARY.
TRY_BASE64_DECODE_STRING   Error-handling version of BASE64_DECODE_STRING.
TRY_HEX_DECODE_BINARY   Error-handling version of HEX_DECODE_BINARY.
TRY_HEX_DECODE_STRING   Error-handling version of HEX_DECODE_STRING.
Hash/Cryptographic MD5 , MD5_HEX    
MD5_BINARY    
MD5_NUMBER    
SHA1 , SHA1_HEX    
SHA1_BINARY    
SHA2 , SHA2_HEX    
SHA2_BINARY