To use an editor to edit your mail message, set the variable VISUAL to the pathname of the editor that you want to use. For example:
set VISUAL=/usr/ucb/vi
This sets the VISUAL variable to the vi editor.