假如字段txtname为text类型的,需要运用函数cast进行中间转换 SELECT * FROM DJPS_LOWDETAIL where cast(txtname as varchar)='张三'