<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	>
<channel>
	<title>Comments on: On associativity, transitivity and reflexivity</title>
	<atom:link href="http://laurentschneider.com/wordpress/2007/09/on-associativity-transitivity-and-reflexivity.html/feed/" rel="self" type="application/rss+xml" />
	<link>http://laurentschneider.com/wordpress/2007/09/on-associativity-transitivity-and-reflexivity.html</link>
	<description>Oracle Certified Master</description>
	<pubDate>Mon, 01 Dec 2008 17:33:19 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.6.5</generator>
		<item>
		<title>By: KevinMiles</title>
		<link>http://laurentschneider.com/wordpress/2007/09/on-associativity-transitivity-and-reflexivity.html#comment-4884</link>
		<dc:creator>KevinMiles</dc:creator>
		<pubDate>Mon, 01 Oct 2007 06:02:38 +0000</pubDate>
		<guid isPermaLink="false">http://laurentschneider.com/wordpress/2007/09/on-associativity-transitivity-and-reflexivity.html#comment-4884</guid>
		<description>Laurent,

The date issue intrigued me, so I investigated further.  I ran a query against a range of dates to see which values were equal and which were different.  Here is the query and its output:

 
&lt;code&gt;
WITH t AS (
  SELECT
    interval '1' month a, 
    interval '7' day c 
  FROM dual ) 
SELECT b, a+(b+c),(a+b)+c FROM t, 
  (SELECT 
    TO_DATE('2007-09-01', 'YYYY-MM-DD') + rownum b 
  FROM ( 
    SELECT null 
    FROM dual 
    CONNECT BY LEVEL &lt;= 31 ));

B         A+(B+C)   (A+B)+C
--------- --------- ---------
02-SEP-07 09-OCT-07 09-OCT-07
03-SEP-07 10-OCT-07 10-OCT-07
04-SEP-07 11-OCT-07 11-OCT-07
05-SEP-07 12-OCT-07 12-OCT-07
06-SEP-07 13-OCT-07 13-OCT-07
07-SEP-07 14-OCT-07 14-OCT-07
08-SEP-07 15-OCT-07 15-OCT-07
09-SEP-07 16-OCT-07 16-OCT-07
10-SEP-07 17-OCT-07 17-OCT-07
11-SEP-07 18-OCT-07 18-OCT-07
12-SEP-07 19-OCT-07 19-OCT-07
13-SEP-07 20-OCT-07 20-OCT-07
14-SEP-07 21-OCT-07 21-OCT-07
15-SEP-07 22-OCT-07 22-OCT-07
16-SEP-07 23-OCT-07 23-OCT-07
17-SEP-07 24-OCT-07 24-OCT-07
18-SEP-07 25-OCT-07 25-OCT-07
19-SEP-07 26-OCT-07 26-OCT-07
20-SEP-07 27-OCT-07 27-OCT-07
21-SEP-07 28-OCT-07 28-OCT-07
22-SEP-07 29-OCT-07 29-OCT-07
23-SEP-07 30-OCT-07 30-OCT-07  &lt;-- Until this row, values are the same
24-SEP-07 01-NOV-07 31-OCT-07  &lt;-- From here on, values are different
25-SEP-07 02-NOV-07 01-NOV-07
26-SEP-07 03-NOV-07 02-NOV-07
27-SEP-07 04-NOV-07 03-NOV-07
28-SEP-07 05-NOV-07 04-NOV-07
29-SEP-07 06-NOV-07 05-NOV-07
30-SEP-07 07-NOV-07 06-NOV-07
01-OCT-07 08-NOV-07 08-NOV-07  &lt;-- From here on, values are the same again
02-OCT-07 09-NOV-07 09-NOV-07

31 rows selected.
&lt;/code&gt;
 

What I noticed here is that the difference between the two occurred when one of the values was on the border of a month (eg., last day or first day).

I modified the query to show the value of the INTERVAL by modifying the SELECT clause to add in &#34;b+a-b&#34; as a column:

&lt;code&gt;
WITH t AS ( 
  SELECT interval '1' month a, 
    interval '7' day c FROM dual ) 
SELECT b, b+a-b 
FROM t, 
  (SELECT 
    TO_DATE('2007-09-01', 'YYYY-MM-DD') + rownum b 
  FROM ( 
    SELECT null FROM dual CONNECT BY LEVEL &lt;= 31 ));

B              B+A-B
--------- ----------
02-SEP-07         30
03-SEP-07         30
04-SEP-07         30
05-SEP-07         30
06-SEP-07         30
07-SEP-07         30
08-SEP-07         30
09-SEP-07         30
10-SEP-07         30
11-SEP-07         30
12-SEP-07         30
13-SEP-07         30
14-SEP-07         30
15-SEP-07         30
16-SEP-07         30
17-SEP-07         30
18-SEP-07         30
19-SEP-07         30
20-SEP-07         30
21-SEP-07         30
22-SEP-07         30
23-SEP-07         30
24-SEP-07         30
25-SEP-07         30
26-SEP-07         30
27-SEP-07         30
28-SEP-07         30
29-SEP-07         30
30-SEP-07         30
01-OCT-07         31
02-OCT-07         31

31 rows selected.
&lt;/code&gt;
 

What is obvious here is that the value of A changes from 30 for all September dates to 31 for the October dates.  This coincides with the number of days in the respected months.  Another query to demonstrate this difference in the value of INTERVAL: </description>
		<content:encoded><![CDATA[<p>Laurent,</p>
<p>The date issue intrigued me, so I investigated further.  I ran a query against a range of dates to see which values were equal and which were different.  Here is the query and its output:</p>
<p><pre><code>
WITH t AS (
&nbsp;&nbsp;SELECT
&nbsp;&nbsp;&nbsp;&nbsp;interval &#039;1&#039; month a, 
&nbsp;&nbsp;&nbsp;&nbsp;interval &#039;7&#039; day c 
&nbsp;&nbsp;FROM dual ) 
SELECT b, a+(b+c),(a+b)+c FROM t, 
&nbsp;&nbsp;(SELECT 
&nbsp;&nbsp;&nbsp;&nbsp;TO_DATE(&#039;2007-09-01&#039;, &#039;YYYY-MM-DD&#039;) + rownum b 
&nbsp;&nbsp;FROM ( 
&nbsp;&nbsp;&nbsp;&nbsp;SELECT null 
&nbsp;&nbsp;&nbsp;&nbsp;FROM dual 
&nbsp;&nbsp;&nbsp;&nbsp;CONNECT BY LEVEL &lt;= 31 ));

B&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; A+(B+C)&nbsp;&nbsp; (A+B)+C
--------- --------- ---------
02-SEP-07 09-OCT-07 09-OCT-07
03-SEP-07 10-OCT-07 10-OCT-07
04-SEP-07 11-OCT-07 11-OCT-07
05-SEP-07 12-OCT-07 12-OCT-07
06-SEP-07 13-OCT-07 13-OCT-07
07-SEP-07 14-OCT-07 14-OCT-07
08-SEP-07 15-OCT-07 15-OCT-07
09-SEP-07 16-OCT-07 16-OCT-07
10-SEP-07 17-OCT-07 17-OCT-07
11-SEP-07 18-OCT-07 18-OCT-07
12-SEP-07 19-OCT-07 19-OCT-07
13-SEP-07 20-OCT-07 20-OCT-07
14-SEP-07 21-OCT-07 21-OCT-07
15-SEP-07 22-OCT-07 22-OCT-07
16-SEP-07 23-OCT-07 23-OCT-07
17-SEP-07 24-OCT-07 24-OCT-07
18-SEP-07 25-OCT-07 25-OCT-07
19-SEP-07 26-OCT-07 26-OCT-07
20-SEP-07 27-OCT-07 27-OCT-07
21-SEP-07 28-OCT-07 28-OCT-07
22-SEP-07 29-OCT-07 29-OCT-07
23-SEP-07 30-OCT-07 30-OCT-07&nbsp;&nbsp;&lt;-- Until this row, values are the same
24-SEP-07 01-NOV-07 31-OCT-07&nbsp;&nbsp;&lt;-- From here on, values are different
25-SEP-07 02-NOV-07 01-NOV-07
26-SEP-07 03-NOV-07 02-NOV-07
27-SEP-07 04-NOV-07 03-NOV-07
28-SEP-07 05-NOV-07 04-NOV-07
29-SEP-07 06-NOV-07 05-NOV-07
30-SEP-07 07-NOV-07 06-NOV-07
01-OCT-07 08-NOV-07 08-NOV-07&nbsp;&nbsp;&lt;-- From here on, values are the same again
02-OCT-07 09-NOV-07 09-NOV-07

31 rows selected.
</code></pre></p>
<p>What I noticed here is that the difference between the two occurred when one of the values was on the border of a month (eg., last day or first day).</p>
<p>I modified the query to show the value of the INTERVAL by modifying the SELECT clause to add in &quot;b+a-b&quot; as a column:</p>
<p><pre><code>
WITH t AS ( 
&nbsp;&nbsp;SELECT interval &#039;1&#039; month a, 
&nbsp;&nbsp;&nbsp;&nbsp;interval &#039;7&#039; day c FROM dual ) 
SELECT b, b+a-b 
FROM t, 
&nbsp;&nbsp;(SELECT 
&nbsp;&nbsp;&nbsp;&nbsp;TO_DATE(&#039;2007-09-01&#039;, &#039;YYYY-MM-DD&#039;) + rownum b 
&nbsp;&nbsp;FROM ( 
&nbsp;&nbsp;&nbsp;&nbsp;SELECT null FROM dual CONNECT BY LEVEL &lt;= 31 ));

B&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;B+A-B
--------- ----------
02-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
03-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
04-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
05-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
06-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
07-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
08-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
09-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
10-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
11-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
12-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
13-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
14-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
15-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
16-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
17-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
18-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
19-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
20-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
21-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
22-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
23-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
24-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
25-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
26-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
27-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
28-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
29-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
30-SEP-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 30
01-OCT-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 31
02-OCT-07&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 31

31 rows selected.
</code></pre></p>
<p>What is obvious here is that the value of A changes from 30 for all September dates to 31 for the October dates.  This coincides with the number of days in the respected months.  Another query to demonstrate this difference in the value of INTERVAL:</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Laurent Schneider</title>
		<link>http://laurentschneider.com/wordpress/2007/09/on-associativity-transitivity-and-reflexivity.html#comment-4849</link>
		<dc:creator>Laurent Schneider</dc:creator>
		<pubDate>Thu, 27 Sep 2007 12:37:33 +0000</pubDate>
		<guid isPermaLink="false">http://laurentschneider.com/wordpress/2007/09/on-associativity-transitivity-and-reflexivity.html#comment-4849</guid>
		<description>Hi Nigel,
You comment makes sense. In C++, you can redefine the + operator to whatever you want. So you can say that 1 vodka + 1 orange = 1 drink. In my opinion it is a bad practice to redefine the + operator in such a way that it loses its properties. So define string:='Start'+'Finish' loses another property, namely the commutativity ;-)</description>
		<content:encoded><![CDATA[<p>Hi Nigel,<br />
You comment makes sense. In C++, you can redefine the + operator to whatever you want. So you can say that 1 vodka + 1 orange = 1 drink. In my opinion it is a bad practice to redefine the + operator in such a way that it loses its properties. So define string:=&#8217;Start&#8217;+'Finish&#8217; loses another property, namely the commutativity <img src='http://laurentschneider.com/wordpress/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' /></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Nigel Thomas</title>
		<link>http://laurentschneider.com/wordpress/2007/09/on-associativity-transitivity-and-reflexivity.html#comment-4834</link>
		<dc:creator>Nigel Thomas</dc:creator>
		<pubDate>Wed, 26 Sep 2007 18:49:38 +0000</pubDate>
		<guid isPermaLink="false">http://laurentschneider.com/wordpress/2007/09/on-associativity-transitivity-and-reflexivity.html#comment-4834</guid>
		<description>Laurent

The + operator is associative over real numbers (complex ones too, come to that) but there's nothing to say that it has to be associative in all cases. Consider languages where string concatenation is indicated by + 

stringvar := 'Start '+ 'Finish';

No one reading that would expect A + B equivalent to B + A, would they?

It all comes down to defining your universe. 

Regards Nigel</description>
		<content:encoded><![CDATA[<p>Laurent</p>
<p>The + operator is associative over real numbers (complex ones too, come to that) but there&#8217;s nothing to say that it has to be associative in all cases. Consider languages where string concatenation is indicated by + </p>
<p>stringvar := &#8216;Start &#8216;+ &#8216;Finish&#8217;;</p>
<p>No one reading that would expect A + B equivalent to B + A, would they?</p>
<p>It all comes down to defining your universe. </p>
<p>Regards Nigel</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Laurent Schneider</title>
		<link>http://laurentschneider.com/wordpress/2007/09/on-associativity-transitivity-and-reflexivity.html#comment-4833</link>
		<dc:creator>Laurent Schneider</dc:creator>
		<pubDate>Wed, 26 Sep 2007 17:40:51 +0000</pubDate>
		<guid isPermaLink="false">http://laurentschneider.com/wordpress/2007/09/on-associativity-transitivity-and-reflexivity.html#comment-4833</guid>
		<description>I know NULL=NULL is undefined. This is however an abuse of the = operator

If you allow to add months to a date with a function, it is fine, you can define how it works. But if you use the + operator, the + does lose its intrinsic properties</description>
		<content:encoded><![CDATA[<p>I know NULL=NULL is undefined. This is however an abuse of the = operator</p>
<p>If you allow to add months to a date with a function, it is fine, you can define how it works. But if you use the + operator, the + does lose its intrinsic properties</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sokrates</title>
		<link>http://laurentschneider.com/wordpress/2007/09/on-associativity-transitivity-and-reflexivity.html#comment-4832</link>
		<dc:creator>Sokrates</dc:creator>
		<pubDate>Wed, 26 Sep 2007 16:05:06 +0000</pubDate>
		<guid isPermaLink="false">http://laurentschneider.com/wordpress/2007/09/on-associativity-transitivity-and-reflexivity.html#comment-4832</guid>
		<description>you're a great cheater !

your reflexivity example should be

with t as (select null a from dual)
  select case when a=a then 'YES' else 'NO or undefined' end "A=A"
  from t;

A=A
---------------
NO or undefined

because you know quite well SQL is using a three-valued logic
(not 'YES' does NOT imply 'NO')

month / day - arithmetic 
NEVER WAS ASSOCIATIVE IN REAL LIFE
(where did you hear that ?)</description>
		<content:encoded><![CDATA[<p>you&#8217;re a great cheater !</p>
<p>your reflexivity example should be</p>
<p>with t as (select null a from dual)<br />
  select case when a=a then &#8216;YES&#8217; else &#8216;NO or undefined&#8217; end &#8220;A=A&#8221;<br />
  from t;</p>
<p>A=A<br />
&#8212;&#8212;&#8212;&#8212;&#8212;<br />
NO or undefined</p>
<p>because you know quite well SQL is using a three-valued logic<br />
(not &#8216;YES&#8217; does NOT imply &#8216;NO&#8217;)</p>
<p>month / day - arithmetic<br />
NEVER WAS ASSOCIATIVE IN REAL LIFE<br />
(where did you hear that ?)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Laurent Schneider</title>
		<link>http://laurentschneider.com/wordpress/2007/09/on-associativity-transitivity-and-reflexivity.html#comment-4831</link>
		<dc:creator>Laurent Schneider</dc:creator>
		<pubDate>Wed, 26 Sep 2007 13:51:28 +0000</pubDate>
		<guid isPermaLink="false">http://laurentschneider.com/wordpress/2007/09/on-associativity-transitivity-and-reflexivity.html#comment-4831</guid>
		<description>yes, and in leap years, it is common to have leap year baby to have their birthday on March 1st :-)

Thanks Hector, of course there is an explanation! but it breaks the associativity of the addition.</description>
		<content:encoded><![CDATA[<p>yes, and in leap years, it is common to have leap year baby to have their birthday on March 1st <img src='http://laurentschneider.com/wordpress/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<p>Thanks Hector, of course there is an explanation! but it breaks the associativity of the addition.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Hector Gabriel Ulloa Ligarius</title>
		<link>http://laurentschneider.com/wordpress/2007/09/on-associativity-transitivity-and-reflexivity.html#comment-4830</link>
		<dc:creator>Hector Gabriel Ulloa Ligarius</dc:creator>
		<pubDate>Wed, 26 Sep 2007 13:39:16 +0000</pubDate>
		<guid isPermaLink="false">http://laurentschneider.com/wordpress/2007/09/on-associativity-transitivity-and-reflexivity.html#comment-4830</guid>
		<description>Hi Laurent 

This example have a logical explication

with t as (
 select interval '1' month a,
        date '2007-09-26' b,
        interval '7' day c
from dual)
select a+(b+c),(a+b)+c
from t
/

A+(B+C)             (A+B)+C             
------------------- ------------------- 
30-10-2007 00:00:00 30-10-2007 00:00:00 

Brief....

A + B is=2007-10-26 + seven days =&#62; 27 --&#62; 28 --&#62; 29 --&#62; 30 --&#62; 31 --&#62; 01 --&#62; 02 of October 2007

other way 


B + C is=2007-10-03 because 2007-09-26 more(+) seven days --&#62; 27 --&#62; 28 --&#62; 29 --&#62; 30 --&#62; 01 --&#62; 02 --&#62; 03 of September 2007 more(+) one month is 03 October 2007


Another date

SQL&#62; with t as (
  2   select interval '1' month a,
  3          date '2007-07-26' b,
  4          interval '7' day c
  5  from dual)
  6  select a+(b+c),(a+b)+c
  7  from t
  8  /

A+(B+C)             (A+B)+C             
------------------- ------------------- 
02-09-2007 00:00:00 02-09-2007 00:00:00 

is the same!

:D 

Regards
http://ligarius.wordpress.com</description>
		<content:encoded><![CDATA[<p>Hi Laurent </p>
<p>This example have a logical explication</p>
<p>with t as (<br />
 select interval &#8216;1&#8242; month a,<br />
        date &#8216;2007-09-26&#8242; b,<br />
        interval &#8216;7&#8242; day c<br />
from dual)<br />
select a+(b+c),(a+b)+c<br />
from t<br />
/</p>
<p>A+(B+C)             (A+B)+C<br />
&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;- &#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-<br />
30-10-2007 00:00:00 30-10-2007 00:00:00 </p>
<p>Brief&#8230;.</p>
<p>A + B is=2007-10-26 + seven days =&gt; 27 &#8211;&gt; 28 &#8211;&gt; 29 &#8211;&gt; 30 &#8211;&gt; 31 &#8211;&gt; 01 &#8211;&gt; 02 of October 2007</p>
<p>other way </p>
<p>B + C is=2007-10-03 because 2007-09-26 more(+) seven days &#8211;&gt; 27 &#8211;&gt; 28 &#8211;&gt; 29 &#8211;&gt; 30 &#8211;&gt; 01 &#8211;&gt; 02 &#8211;&gt; 03 of September 2007 more(+) one month is 03 October 2007</p>
<p>Another date</p>
<p>SQL&gt; with t as (<br />
  2   select interval &#8216;1&#8242; month a,<br />
  3          date &#8216;2007-07-26&#8242; b,<br />
  4          interval &#8216;7&#8242; day c<br />
  5  from dual)<br />
  6  select a+(b+c),(a+b)+c<br />
  7  from t<br />
  8  /</p>
<p>A+(B+C)             (A+B)+C<br />
&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;- &#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-<br />
02-09-2007 00:00:00 02-09-2007 00:00:00 </p>
<p>is the same!</p>
<p> <img src='http://laurentschneider.com/wordpress/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' /> </p>
<p>Regards<br />
<a href="http://ligarius.wordpress.com" rel="nofollow">http://ligarius.wordpress.com</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: APC</title>
		<link>http://laurentschneider.com/wordpress/2007/09/on-associativity-transitivity-and-reflexivity.html#comment-4829</link>
		<dc:creator>APC</dc:creator>
		<pubDate>Wed, 26 Sep 2007 13:35:24 +0000</pubDate>
		<guid isPermaLink="false">http://laurentschneider.com/wordpress/2007/09/on-associativity-transitivity-and-reflexivity.html#comment-4829</guid>
		<description>&#62;&#62;  No, I said : “equal may imply some transformation” (I meant casting to number).

Oh.  How stupid do I feel?

&#62;&#62;  note that with interval, it is a dangerous mission to deal with months

Fortunately, having worked through the business rules I only need to work with intervals of years.  But I still need to worry about leap years.  Sigh.

Cheers, APC</description>
		<content:encoded><![CDATA[<p>&gt;&gt;  No, I said : “equal may imply some transformation” (I meant casting to number).</p>
<p>Oh.  How stupid do I feel?</p>
<p>&gt;&gt;  note that with interval, it is a dangerous mission to deal with months</p>
<p>Fortunately, having worked through the business rules I only need to work with intervals of years.  But I still need to worry about leap years.  Sigh.</p>
<p>Cheers, APC</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Laurent Schneider</title>
		<link>http://laurentschneider.com/wordpress/2007/09/on-associativity-transitivity-and-reflexivity.html#comment-4828</link>
		<dc:creator>Laurent Schneider</dc:creator>
		<pubDate>Wed, 26 Sep 2007 11:15:22 +0000</pubDate>
		<guid isPermaLink="false">http://laurentschneider.com/wordpress/2007/09/on-associativity-transitivity-and-reflexivity.html#comment-4828</guid>
		<description>note that with interval, it is a dangerous mission to deal with months, because adding one month to 31-JAN result in ORA-01839: date not valid for month specified</description>
		<content:encoded><![CDATA[<p>note that with interval, it is a dangerous mission to deal with months, because adding one month to 31-JAN result in ORA-01839: date not valid for month specified</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Laurent Schneider</title>
		<link>http://laurentschneider.com/wordpress/2007/09/on-associativity-transitivity-and-reflexivity.html#comment-4827</link>
		<dc:creator>Laurent Schneider</dc:creator>
		<pubDate>Wed, 26 Sep 2007 11:10:46 +0000</pubDate>
		<guid isPermaLink="false">http://laurentschneider.com/wordpress/2007/09/on-associativity-transitivity-and-reflexivity.html#comment-4827</guid>
		<description>No, I said : "equal may imply some transformation" (I meant casting to number).

That is why in oracle a=b and b=c does not imply a=c, so the equal operator is not absolutely transitive. I almost included this one about neutral element, but I thought it is too special

In addition the neutral element is supposed to be 0


&lt;code&gt;
with t as (select time '12:34:56.789' t, interval '999999999' day(9) i from dual) 
select case when t+i=t and i!=interval '0' second then 'YES           ' else 'NO ' end 
  "T+I=T AND I!=0" 
from t;
T+I=T AND I!=0
--------------
YES
&lt;/code&gt;</description>
		<content:encoded><![CDATA[<p>No, I said : &#8220;equal may imply some transformation&#8221; (I meant casting to number).</p>
<p>That is why in oracle a=b and b=c does not imply a=c, so the equal operator is not absolutely transitive. I almost included this one about neutral element, but I thought it is too special</p>
<p>In addition the neutral element is supposed to be 0</p>
<p><pre><code>
with t as (select time &#039;12:34:56.789&#039; t, interval &#039;999999999&#039; day(9) i from dual) 
select case when t+i=t and i!=interval &#039;0&#039; second then &#039;YES&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &#039; else &#039;NO &#039; end 
&nbsp;&nbsp;&quot;T+I=T AND I!=0&quot; 
from t;
T+I=T AND I!=0
--------------
YES
</code></pre></p>
]]></content:encoded>
	</item>
</channel>
</rss>
