如果是非英文字符

如果是非英文字符的,最好加binary修饰符,例如:
select x from xx where binary xx like '%徐%';
但仍旧可能会把不包含'徐'字的内容给检索出来,比较好的办法就是用utf-8字符集来存储,并且指定是utf-8校验字符集。

欢迎来到MySQL中文网: http://imysql.cn

给你的祝福,要让你招架不住!

回复

此内容将保密,不会被其他人看见。
  • 允许的 HTML 标签: <a> <b> <address> <blockquote> <br> <caption> <center> <code> <dd> <del> <div> <dl> <dt> <em> <font> <h2> <h3> <h4> <h5> <h6> <hr> <i> <img> <li> <ol> <p> <pre> <span> <strong> <sub> <sup> <table> <tbody> <td> <tfoot> <th> <thead> <tr> <u> <ul> <tr>
  • 行和段被自动切分。
  • 网页地址和电子邮件地址将会被自动转换为链接。

更多格式化选项信息

随机验证
本功能用于防止垃圾信息
在输入框中输入图片上的字符(注意大小写)