A first approximation can be achieved using the standard character classes:
1> regexp:first_match("OTPErlang", "^[A-Za-z]+$").
{match,1,9}
2> regexp:first_match("123-Have Fun", "^[A-Za-z]+$").
nomatch
3> case regexp:match("Soup", "^[A-Za-z]+$") of
3> {match,_,_} -> io:fwrite("I like alphabet soup!\n");
3> true -> io:fwrite("I don't like number soup.\n")
3> end.
I like alphabet soup!
ok
If you need to match alternative alphabets (as defined by the user's locale settings), you will have to identify the proper character codes for the additional characters and add them to the search routine. Erlang's built-in regular expression support is pretty miserable here.
As discussed in other recipes, Erlang is fully capable of processing any Unicode string (because it stores srings as lists of integers). However, Erlang is really not fully Unicode compliant because its regular expression engine does not support characters outside the standard ASCII set.