【问题标题】:Find values with 2 or more consecutive numeric characters (SQL)查找具有 2 个或更多连续数字字符的值 (SQL)
【发布时间】:2019-07-31 19:12:37
【问题描述】:

我有一列有时有连续数字的值,我怎样才能得到所有 2+ 个连续数字字符的值?例如:

value
-------
car1339
foo3bar9
there10yes
hellothere

获取以下内容的 SQL 语句是什么?

car1339
there10yes

【问题讨论】:

  • ... 像 '%[0-9][0-9]%' 这样的值

标签: sql-server


【解决方案1】:

SQL DEMO

SELECT *
FROM Table1
WHERE value LIKE '%[0-9][0-9]%' ;

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2021-07-30
    • 2020-10-25
    • 1970-01-01
    • 1970-01-01
    • 2022-01-01
    • 1970-01-01
    • 2021-06-20
    相关资源
    最近更新 更多