pub trait Like<const HAS_ESCAPE: bool> {
type Err;
fn like(&self, pattern: &Self) -> Result<bool, Self::Err>;
fn not_like(&self, pattern: &Self) -> Result<bool, Self::Err> { ... }
}
Expand description
SQL like
style pattern matching.
If pattern
does not contain %
or _
, then the pattern only represents the pattern
itself;
in that case like
acts like the equals operator.
An underscore (_
) in pattern stands for (matches) any single character;
a percent sign (%
) matches any sequence of zero or more characters.