Re: Alternative to Check Constraints

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance

anonymous_at_discussions.microsoft.com
Date: 04/23/04


Date: Fri, 23 Apr 2004 11:03:01 -0700

Thanks David,

So is it correct that I was erroniously thinking that a
new mechanism was devised by Microsoft to do what check
constraints do but in a centralized and database driven
way. I thought that there was some table that we could
add a constraint to just as easily as we can add a record
to any other table. And the system would upon updates and
inserts check this table to make sure that the constraints
are applied.

>-----Original Message-----
>CHECK constraints can be viewed through an Information
Schema view as
>follows:
>
>SELECT * FROM information_schema.CHECK_CONSTRAINTS
>
>This view references the syscomments and sysobjects
system tables.
>
>This is NOT an alternative to or substitute for CHECK
constraints - it
>simply allows you to view that information. You can't
update the system
>tables and you still have to create the constraints
themselves through a
>CREATE or ALTER table statement.
>
>--
>David Portas
>SQL Server MVP
>--
>
>
>.
>



Relevant Pages

  • Re: Basic question?What s the key if there s no FD(Functional Dependencies)?
    ... updatability but several ones that can all be correct depending on what ... a set of view updates VU that is a subset of J x J ... One can not talk of the database without constraints, ... certain simple types of equality generating dependencies ...
    (comp.databases.theory)
  • Re: On specialization constraints time of application
    ... tuples in base relations represent things that no longer exist, ...  The point in time that that set of deletes, updates and/or ... inserts is submitted is the time that constraints should be evaluated. ... database, and the constraint engine need only be concerned with what is ...
    (comp.databases.theory)
  • Re: On specialization constraints time of application
    ... The point in time that that set of deletes, updates and/or ... inserts is submitted is the time that constraints should be evaluated. ... database, and the constraint engine need only be concerned with what is ... For those expressions for which there isn't a translation, ...
    (comp.databases.theory)
  • Re: Disabling check constraints
    ... I want to be able to disable constraints, perform a number of updates, ... I need to update some key values on tables that have Foreign Key ...
    (comp.databases.oracle.server)
  • Re: Disabling check constraints
    ... I want to be able to disable constraints, perform a number of updates, ... during the batch but by the end everything should be consistent. ... Puget Sound Oracle Users Group ...
    (comp.databases.oracle.server)