MSSQL: Update statement avoiding the CHECK constraint
问题 Working in MS2000, I have a table called JobOwners that maps Jobs (JPSID) to the Employees that own them (EmpID). It also contains the date they started owning that job (DateStarted), date they stopped owning that job (DateEnded) and if the ownership is active (IsActive). Looks like this. CREATE TABLE JobOwners ( LogID int NOT NULL IDENTITY(1,1) PRIMARY KEY, JPSID int NOT NULL FOREIGN KEY REFERENCES JobsPerShift(JPSID), EmpID int NOT NULL FOREIGN KEY REFERENCES Employees(EmpID), DateStarted