简体   繁体   English

SQL:正则表达式

[英]SQL: Regular Expressions `

I need to have a sql rexeg pattern that matches any number between 42.67 and 42.86 我需要一个SQL rexeg模式,它匹配42.67和42.86之间的任何数字

This is what i Have, but I am not sure if its working 这就是我所拥有的,但是我不确定它是否有效

42\.[6-9][0-6]

Can anyone help ? 有人可以帮忙吗? Thanks !! 谢谢 !!

I am using an analytics program that only accepts sql regex i do not have access to the db to run queries against it. 我正在使用仅接受sql regex的分析程序,但我无权访问该数据库以对其执行查询。

尝试这个:

42\.(6[7-9]|7[0-9]|8[0-6])

Why do you need a regex? 为什么需要正则表达式? Just select column from table where column>=42.67 and column<=42.86; 只需从表中选择列> column。= 42.67和column <= 42.86;

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM