Oracle中like查询下划线等特殊字符的处理ESCAPE Clause ExampleYou can include the actual characters "%" or "_" in the pattern by using the ESCAPEclause, which identifies the escape character. If the escape characterappears in the pattern before the character "%" or "_" then Oracleinterprets this character literally in the pattern, rather than as aspecial pattern matching character. To search for employees with the pattern 'A_B' in their name: oracle like 匹配下划线SELECT last_name oracle like 匹配下划线    FROM employees oracle like 匹配下划线    WHERE last_name LIKE '%A\_B%' ESCAPE '\'; oracle like 匹配下划线The ESCAPE clause identifies the backslash(\) as the escape character. In the pattern, the escape characterprecedes the underscore (_). This causes Oracle to interpret theunderscore literally, rather than as a special pattern matchingcharacter.

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-02-04
猜你喜欢
  • 2022-12-23
  • 2022-02-09
  • 2022-12-23
  • 2021-09-04
  • 2021-11-14
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案