Added via ALTER TABLE ... ADD CONSTRAINT name CHECK (expr), this Delta rule requires a deterministic Boolean expression to be true for each row. Current rows are validated before it takes effect, and writes that would break it fail.
Read more: Microsoft Learn
In the Ultra Transcenders books
Each book explains CHECK constraint in context, with comparison tables and the common traps.
Terms in this definition
- Veeam Infrastructure Appliance
A hardened, minimal Linux (JeOS) ISO for running backup proxies, repositories and hardened repositories. It connects to a backup server but does not host one.
- Event
Table in Log Analytics where entries from Windows event logs are kept.
- Architecture Definition Document
A key deliverable bringing together the main architecture artifacts across the four domains for every relevant state: baseline, transition and target. It sets out, in qualitative terms, what the architect intends.
- Constraint
Set by someone other than the architect, it fixes a limit the design cannot change, such as reusing existing hardware, a fixed budget or having just one data centre. Its effect is recorded and worked around, and any gap it leaves is logged as a risk.
- DETERMINISTIC
Tells the engine, in
CREATE FUNCTION, that identical inputs always give identical outputs, which can help optimisation. The engine takes this on trust and does not verify it against the function's code.
Related terms
- ISJSON
Checks a string and returns whether its contents are valid JSON. A CHECK constraint of the form CHECK (ISJSON(col) = 1) uses it to keep nvarchar columns free of malformed JSON.
- JSON_PATH_EXISTS
Returns 1 when a given SQL/JSON path is present in some JSON and 0 when it isn't. Put inside a CHECK constraint, this T-SQL function can make sure a property is always there.