Help Center Knowledge Base

(KB-00002) "What are Regular Expre..."

What are Regular Expressions?

A regular expression (abbreviated "regex") is an expression that describes a piece of text in the form of a pattern. It is most often used to either search for or compare a given text with a certain pattern.

The Regular Expression describes a piece of text in general terms, such as "must start with a letter, may contain digits, and must not be longer than 5 characters." This description is encoded into a formal pattern, which in this case would read ^[:alpha:].{,4}$. Each character in this pattern has a special meaning which describes a part of the rule to compare the text against.

Regular Expressions are often used inside programs to validate certain data (for examle, whether a phone number the user has entered has the format of a valid phone number.) Some text editors and wor processors allow you to search inside a document by using a Regular Expression.

Regular Expressions are often complex beasts and can be tricky to construct. Fortunately, there is a very helpful tool available that helps you construct and test your regex patterns: ReX-T by Esclepius Software LLC.

Was this document helpful?
Thanks for voting!

Document Metadata

Viewed
Viewed by 2198 users; 648 found this helpful
Created
08/27/2018 2:28:58 PM by (admin) Administrator
Keywords
regex, regular expression, regular expressions, faq, rext