當 SET ANSI_NULLS 是 ON 時,比較一個或多個 Null 運算式不會產生 TRUE 或 FALSE 的結果,而會產生 UNKNOWN。這是因為未知的值無法與任何值進行邏輯比較。如果運算式與常值 NULL 比較,或是兩個運算式互相比較但其中有一個是 NULL 值,就會發生此狀況。(Technet)在沒特別設置的情況下,ANSI_NULLS 皆是預設為ON,
When you subscribe to the blog, we will send you an e-mail when there are new updates on the site so you wouldn't miss them.
評論