gxlaqj

1:以字段开头模糊查询的like的方法查询

select * from t  where  t.user_code like \'A%\'

2:以字段开头模糊查询的left(字段,长度)的方法查询

select * from t  where left(t.user_code, 1)=\'A\';

3:字符间隔查询段对应的值以 1,4,6 的格式查询使用find_in_set

select * from t  where FIND_IN_SET(\'1\',t.name);//t.name所查询的字段,所有包含1的数据
---------------------
作者:彼岸_梦
来源:CSDN
原文:https://blog.csdn.net/zhanxiaochu/article/details/81381627
版权声明:本文为博主原创文章,转载请附上博文链接!

分类:

技术点:

相关文章:

  • 2021-12-10
  • 2021-11-18
  • 2021-12-02
  • 2021-11-22
  • 2021-11-03
  • 2021-09-28
  • 2018-12-21
猜你喜欢
  • 2021-10-19
  • 2022-01-08
  • 2021-10-24
  • 2018-04-08
  • 2021-08-06
  • 2021-12-02
  • 2022-01-08
相关资源
相似解决方案