DbContextConfiguration.UseDatabaseNullSemantics Property


Gets or sets a value indicating whether database null semantics are exhibited when comparing two operands, both of which are potentially nullable. The default value is false.

For example (operand1 == operand2) will be translated as:

(operand1 = operand2)

if UseDatabaseNullSemantics is true, respectively

(((operand1 = operand2) AND (NOT (operand1 IS NULL OR operand2 IS NULL))) OR ((operand1 IS NULL) AND (operand2 IS NULL)))

if UseDatabaseNullSemantics is false.

public bool UseDatabaseNullSemantics { get; set; }
member this.UseDatabaseNullSemantics : bool with get, set
Public Property UseDatabaseNullSemantics As Boolean

Property Value

true if database null comparison behavior is enabled, otherwise false .

Applies to