Redian新闻
>
in DBMS, is NULL=NULL valid?
avatar
f*g
2

A value of NULL indicates the value is unknown. A value of NULL is different
from an empty or zero value. No two null values are equal. Comparisons between
two null values, or between a NULL and any other value, return unknown because
the value of each NULL is unknown.
Null values usually indicate data that is unknown, not applicable, or to be
added at a later time. For example, a customer's middle initial may not be
known at the time the customer places an order.

【在 s**********r 的大作中提到】
: why? thanks
avatar
s*i
3

NULL is NULL. null is not unkown. if you know a value
is null, it's not any other value, it's just null.
basically null means no set value.

【在 f***g 的大作中提到】
:
: A value of NULL indicates the value is unknown. A value of NULL is different
: from an empty or zero value. No two null values are equal. Comparisons between
: two null values, or between a NULL and any other value, return unknown because
: the value of each NULL is unknown.
: Null values usually indicate data that is unknown, not applicable, or to be
: added at a later time. For example, a customer's middle initial may not be
: known at the time the customer places an order.

avatar
h*e
4
nop, NULL is NULL, which means uncomparable "value", if this makes some
sense to you.

【在 s**********r 的大作中提到】
: why? thanks
avatar
l*h
5
What did you try to do?
Why did you want to compare NULL to NULL?
Could you provide your SQL statement?

【在 s**********r 的大作中提到】
: why? thanks
avatar
h*n
6
well, maybe this is useful for dating service, bf/gf search engine. :P
select a.ID, a.FirstName, a.LastName, b.ID, b.FirstName, b.LastName
from Male a, Female b
where ( a.GirlFriendID IS NULL and a.IsGay = FALSE and
b.BoyFriendID IS NULL and b.IsLesbian = FALSE)

【在 l********h 的大作中提到】
: What did you try to do?
: Why did you want to compare NULL to NULL?
: Could you provide your SQL statement?

相关阅读
logo
联系我们隐私协议©2024 redian.news
Redian新闻
Redian.news刊载任何文章,不代表同意其说法或描述,仅为提供更多信息,也不构成任何建议。文章信息的合法性及真实性由其作者负责,与Redian.news及其运营公司无关。欢迎投稿,如发现稿件侵权,或作者不愿在本网发表文章,请版权拥有者通知本网处理。