SQL Server 2005 - How can I do a Reg Exp in T-SQL

 ̄綄美尐妖づ 提交于 2020-01-05 06:52:27

问题


Is there any way I can perform a Regular Expression search using T-SQL in SQL Server 2005 without having to load a .Net Assembly?


回答1:


It seems that you can do it with VBScript, but it's not very pretty.




回答2:


Unfortunately, the only way I know is by using a CLR udf as described in http://msdn.microsoft.com/en-us/magazine/cc163473.aspx




回答3:


Dan Farino seems to have written an SP for SQL Server exactly for the purpose of using regex without having to install a .NET framework for CLR. Looks promising.



来源:https://stackoverflow.com/questions/4120358/sql-server-2005-how-can-i-do-a-reg-exp-in-t-sql

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!