PostgreSQL:获取所有包含大写字母的行



如何执行以下stmt:

select * from table
where column has any uppercase letters; <-- how to write this

您可以使用正则表达式进行筛选:

select * 
from mytable
where mycolumn ~ '[A-Z]'

另一种方法是字符串比较:

select * 
from mytable
where lower(mycolumn) <> mycolumn

相关内容

最新更新