Left, right, and mid functions

To use these functions, choose Calc > Calculator.

The Left function returns the specified number of characters from the beginning of a string of text. The Right function returns the specified number of characters from the end of a string of text. The Mid function returns a substring of characters within a string of text, given the starting position and the length of the substring.

Syntax

  • LEFT(text,num_chars)
  • RIGHT(text,num_chars)
  • MID(text,start_num,[num_chars])

For text, specify the text or the column of text values. For num_chars, indicate how many characters from the left or right you want to retain (optional for the MID function). For start_num, specify the position of the first character to return.

Examples

Column Calculator expression Result
C1 contains "Defective" LEFT(C1,3) Def
C1 contains "autocontrol" RIGHT(C1,7) control
C1 contains "ITtechnician" MID(C1,3,4) tech