I'm confused of predicate and constraints.
What is the difference between these two?
Technology Tips and News
I'm confused of predicate and constraints.
What is the difference between these two?
Predicate and Constraints are two different things in SQL Server. There is no comparison between.
Refer the below to know more on the subject:
Predicate:
https://msdn.microsoft.com/en-us/library/ms189523.aspx?f=255&MSPPError=-2147217396
http://blogs.msdn.com/b/craigfr/archive/2006/07/07/652668.aspx
Constraints:
https://technet.microsoft.com/en-us/library/ms189862(v=sql.105).aspx
Good day dy0803,
This is a bit like asking what is the difference between an animal and a dog :-)
Predicates are expression that evaluates to TRUE, FALSE, or UNKNOWN. CONTAINS is one of the Predicates that SQL Server provides.
Predicates are expressions that we can use them in WHERE clause.
more info: Predicates
Constraints are used to check rules.
more info: SQL Constraints