Pattern Matching PDF
Pattern Matching PDF
1. LIKE statements
3. ~ (Regular Expressions)
Start-Tech Academy
LIKE WILDCARDS
The PostgreSQL LIKE condition allows you to perform pattern matching using Wildcards.
Wildcard Explanation
% Allows you to match any string of any length (including zero length)
_ Allows you to match on a single character
AB_C means string starts with AB, then there is one character, then there is C
Start-Tech Academy
LIKE
The PostgreSQL LIKE condition allows you to perform pattern matching using Wildcards.
Start-Tech Academy
WILDCARDS
Wildcard Explanation
| Denotes alternation (either of two alternatives).
* Denotes repetition of the previous item zero or more times
+ Denotes repetition of the previous item one or more times.
? Denotes repetition of the previous item zero or one time.
Start-Tech Academy