---
title: "查询有汉字或字母的语句"
author: "dyclh"
date: "2013-06-17T22:59:45Z"
tags: []
categories: ["数据库"]
slug: "untitled"
draft: false
lastmod: "2013-06-17T22:59:45Z"
id: 1888431
url: "https://dyclh.iteye.com/blog/1888431"
---

select *  , case  
   when status=1 then '临时会员'  
    when status=2 then '注册会员'  
     when status=0 then '冻结帐户'  
   else ''  
end

from tb\_user  
where  
isnull(account,'')&lt;&gt;'' and (account  like  '%\[吖-座]%' or  
 account  like '%\[a-z]%'   
 or account like '%-%' or account like '% %'  )   order by status