这个检查约束是什么意思(不是 [EXIST_code] 像 '%[^-0-9A-Z_/&$!]%')

what does this check constraint means (NOT [EXIST_code] like '%[^-0-9A-Z_/&$!]%')

这个检查约束定义是什么意思?

(NOT [EXIST_code] like '%[^-0-9A-Z_/&$!]%')

操作:

  NOT LIKE 

in SQL 用于 varchar 类型的列。通常,它与 % 一起使用,用于表示任何字符串值,包括空字符 \0.

可能必须了解您的正则表达式并了解如何根据异常检索数据:)

正则表达式表示:

匹配不在下面列表中的单个字符 [^-0-9A-Z_/&$!]:

- matches the character - literally (case sensitive)
0-9 a single character in the range between 0 (index 48) and 9 (index 57) (case sensitive)
A-Z a single character in the range between A (index 65) and Z (index 90) (case sensitive)
_/&$! matches a single character in the list _/&$! (case sensitive)