本文介绍了如何更改SQL Server中列的现有规则的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
How to Alter the Existing Rule on a Column in SQL Server
创建规则[dbo ]。[AccountStatus]为@AccountStatus in('A','C','N','T','I','D','F','M')
我想绑定更多状态
我尝试了什么:
ALTER规则[dbo]。[AccountStatus]为@AccountStatus in('A','C','N','T','I', 'D','F','M',
'X','R','Y')
Create rule [dbo].[AccountStatus] as @AccountStatus in ('A','C','N','T','I','D','F','M')
I want to Bind more Statuses
What I have tried:
ALTER rule [dbo].[AccountStatus] as @AccountStatus in ('A','C','N','T','I','D','F','M',
'X','R','Y')
推荐答案
DROP RULE [AccountStatus] as @AccountStatus
EXEC sp_unbindrule 'BsmasterAcnt.AccountStatus'
EXEC sp_bindrule 'AccountStatus','Bsmasteracnt.AccountStatus'
这篇关于如何更改SQL Server中列的现有规则的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!