Re: NULLs: theoretical problems?
From: V.J. Kumar <vjkmail_at_gmail.com>
Date: Wed, 22 Aug 2007 00:06:16 +0200 (CEST)
Message-ID: <Xns9993B831DB5DEvdghher_at_194.177.96.26>
>> Jan Hidders <hidd..._at_gmail.com> wrote
>> innews:1187723867.532149.53830_at_57g2000hsv.googlegroups.com:
>>
>>
>>
>> > On 21 aug, 17:19, "V.J. Kumar" <vjkm..._at_gmail.com> wrote:
>> >> Jan Hidders <hidd..._at_gmail.com> wrote
>> >> innews:1187699645.789970.23980_at_57g2000hsv.googlegroups.com:
>>
>> >> > On 21 aug, 01:13, "V.J. Kumar" <vjkm..._at_gmail.com> wrote:
>> >> >> Jan Hidders <hidd..._at_gmail.com> wrote
>> >> >> innews:1187645998.798282.58960_at_g4g2000hsf.googlegroups.com:
>>
>> >> >> > On 20 aug, 17:14, "V.J. Kumar" <vjkm..._at_gmail.com> wrote:
>> >> >> >> Jan Hidders <hidd..._at_gmail.com> wrote in
>> >> >> >> news:1187599195.269472.153110 _at_a39g2000hsc.googlegroups.com:
>>
>> >> >> >> > On 20 aug, 01:48, "V.J. Kumar" <vjkm..._at_gmail.com> wrote:
>> >> >> >> >> I wonder what the truth tables for 'AND' and 'OR' would
>> >> >> >> >> look like with the DEF operator. Could you show those
>> >> >> >> >> tables ?
>>
>> >> >> >> > They would be the usual table you already gave:
>>
>> >> >> >> >> x y AND
>> >> >> >> >> -------
>> >> >> >> >> defined
>> >> >> >> >> 0 0 0
>> >> >> >> >> 1 0 0
>> >> >> >> >> 0 1 0
>> >> >> >> >> 1 1 1
>>
>> >> >> >> What is 'x AND y' equal to if x is '1' and y is not defined
>> >> >> >> ?
>>
>> >> >> > The database would not allow you to write that. If y is
>> >> >> > nullable then it forces you to write "DEF y : x AND y".
>>
>> >> >> What is DEF y : x AND y equal to if x is '1' and y is not
>> >> >> defined ?
>>
>> >> > False. Because DEF y : f(y) means that (1) y is defined and (2)
>> >> > f(y) holds.
>>
>> >> So you convert undefined operands in your logical formulas to
>> >> 'false'.
>>
>> > No. There is no conversion necessary. That's the whole point.
>>
>> I do not understand. You have:
>>
>> DEF y y DEF y:y
>> 1 1 1 (1)
>> 1 0 0 (2)
>> 0 0 (3)
>>
>> So 'DEF y:y' will give the same result when y is either undefined or
>> 'false', rows (2) and (3). How is it not substituting 'false' for
>> undefined ?
I do not understand. Could you show what you mean with an example ?
Date: Wed, 22 Aug 2007 00:06:16 +0200 (CEST)
Message-ID: <Xns9993B831DB5DEvdghher_at_194.177.96.26>
Jan Hidders <hidders_at_gmail.com> wrote in news:1187729150.610272.117790_at_r29g2000hsg.googlegroups.com:
> On 21 aug, 22:20, "V.J. Kumar" <vjkm..._at_gmail.com> wrote:
>> Jan Hidders <hidd..._at_gmail.com> wrote
>> innews:1187723867.532149.53830_at_57g2000hsv.googlegroups.com:
>>
>>
>>
>> > On 21 aug, 17:19, "V.J. Kumar" <vjkm..._at_gmail.com> wrote:
>> >> Jan Hidders <hidd..._at_gmail.com> wrote
>> >> innews:1187699645.789970.23980_at_57g2000hsv.googlegroups.com:
>>
>> >> > On 21 aug, 01:13, "V.J. Kumar" <vjkm..._at_gmail.com> wrote:
>> >> >> Jan Hidders <hidd..._at_gmail.com> wrote
>> >> >> innews:1187645998.798282.58960_at_g4g2000hsf.googlegroups.com:
>>
>> >> >> > On 20 aug, 17:14, "V.J. Kumar" <vjkm..._at_gmail.com> wrote:
>> >> >> >> Jan Hidders <hidd..._at_gmail.com> wrote in
>> >> >> >> news:1187599195.269472.153110 _at_a39g2000hsc.googlegroups.com:
>>
>> >> >> >> > On 20 aug, 01:48, "V.J. Kumar" <vjkm..._at_gmail.com> wrote:
>> >> >> >> >> I wonder what the truth tables for 'AND' and 'OR' would
>> >> >> >> >> look like with the DEF operator. Could you show those
>> >> >> >> >> tables ?
>>
>> >> >> >> > They would be the usual table you already gave:
>>
>> >> >> >> >> x y AND
>> >> >> >> >> -------
>> >> >> >> >> defined
>> >> >> >> >> 0 0 0
>> >> >> >> >> 1 0 0
>> >> >> >> >> 0 1 0
>> >> >> >> >> 1 1 1
>>
>> >> >> >> What is 'x AND y' equal to if x is '1' and y is not defined
>> >> >> >> ?
>>
>> >> >> > The database would not allow you to write that. If y is
>> >> >> > nullable then it forces you to write "DEF y : x AND y".
>>
>> >> >> What is DEF y : x AND y equal to if x is '1' and y is not
>> >> >> defined ?
>>
>> >> > False. Because DEF y : f(y) means that (1) y is defined and (2)
>> >> > f(y) holds.
>>
>> >> So you convert undefined operands in your logical formulas to
>> >> 'false'.
>>
>> > No. There is no conversion necessary. That's the whole point.
>>
>> I do not understand. You have:
>>
>> DEF y y DEF y:y
>> 1 1 1 (1)
>> 1 0 0 (2)
>> 0 0 (3)
>>
>> So 'DEF y:y' will give the same result when y is either undefined or
>> 'false', rows (2) and (3). How is it not substituting 'false' for
>> undefined ?
> > In the way that if y is undefined then "DEF y : f" is not always > equivalent with "f[y/false]" i.e. "f" with all free occurrence of y > replaced with "false". >
I do not understand. Could you show what you mean with an example ?
> -- Jan Hidders > >Received on Wed Aug 22 2007 - 00:06:16 CEST