select * from customer where name like '\%' 或者 select * from customer where name like '|%' ESCAPE '|' ESCAPE '|'中的|任意
like '\%'以下摘自 MySQL 5.1 Reference Manual The “\%” and “\_” sequences are used to search for literal instances of “%” and “_” in pattern-matching contexts where they would otherwise be interpreted as wildcard characters. See the description of the LIKE operator in Section 11.4.1, “String Comparison Functions”. If you use “\%” or “\_” in non-pattern-matching contexts, they evaluate to the strings “\%” and “\_”, not to “%” and “_”. . [align=center]====思想重于技巧==== [/align] . 贴子分数<20:对自已的问题不予重视。 贴子大量未结:对别人的回答不予尊重。 .
select * from customer where name like '\%'
或者
select * from customer where name like '|%' ESCAPE '|'
ESCAPE '|'中的|任意
The “\%” and “\_” sequences are used to search for literal instances of “%” and “_” in pattern-matching contexts where they would otherwise be interpreted as wildcard characters. See the description of the LIKE operator in Section 11.4.1, “String Comparison Functions”. If you use “\%” or “\_” in non-pattern-matching contexts, they evaluate to the strings “\%” and “\_”, not to “%” and “_”. .
[align=center]==== 思想重于技巧 ====
[/align]
.
贴子分数<20:对自已的问题不予重视。
贴子大量未结:对别人的回答不予尊重。
.
SQL 1992
MySQL 5.1 Reference Manual
ActiveX Data Objects 2.5 Reference 下载
数据库系统概论PPT.
[align=center]==== 思想重于技巧 ====
[/align]
.
贴子分数<20:对自已的问题不予重视。
贴子大量未结:对别人的回答不予尊重。
.
检索出name 中含有'%'的所有字段