MSSQL Regular expression

后端 未结 3 1669
深忆病人
深忆病人 2020-12-03 05:01

I have the following REGEX: ^[-A-Za-z0-9/.]+$

This currently checks whether the value entered into a textbox matches this. If not, it throws an error.

I need

3条回答
  •  天命终不由人
    2020-12-03 05:34

    As above the question was originally about MySQL

    Use REGEXP, not LIKE:

    SELECT * FROM `table` WHERE ([url] NOT REGEXP '^[-A-Za-z0-9/.]+$')
    

提交回复
热议问题