ends_with

description

Syntax

BOOLEAN ENDS_WITH (VARCHAR str, VARCHAR suffix)

如果字符串以指定后缀结尾,返回true。否则,返回false。任意参数为NULL,返回NULL。

example

  1. mysql> select ends_with("Hello doris", "doris");
  2. +-----------------------------------+
  3. | ends_with('Hello doris', 'doris') |
  4. +-----------------------------------+
  5. | 1 |
  6. +-----------------------------------+
  7. mysql> select ends_with("Hello doris", "Hello");
  8. +-----------------------------------+
  9. | ends_with('Hello doris', 'Hello') |
  10. +-----------------------------------+
  11. | 0 |
  12. +-----------------------------------+

keyword

ENDS_WITH