I have this table:
CREATE TABLE [tblExample](
[ExampleID] [int] IDENTITY(1,1) NOT NULL,
[WordsAndStuff] [nvarchar](max) NOT NULL,
[Active] [bit] NOT NULL
I want the Active column to have a unique constraint that will only allow one record to be true (1). At this point, I don't need there to BE a true record all the time, there just cannot be more than one of them.
How do I write the constraint?