Home Page for the TeradataForum
 

Archives of the TeradataForum

Message Posted: Wed, 11 Feb 2004 @ 17:09:07 GMT


     
  <Prev Next>   <<First <Prev Next> Last>>  


Subj:   Re: EXISTS predicate bug?
 
From:   Victor Sokovin

Bill,

  My question is, does it really make a difference? If it is true, you would get a row count of one and an empty data set. If the result is false, you get a row count of zero and an empty data set. In the final results, what is the difference between the two empty sets?  


If you are asking me, I am sorry but I don't really understand your question, especially the part about two empty sets.

As I see it, we have one empty set on which we first calculate MAX and then evaluate EXISTS on the subquery. According to the ANSI standards (in my reading at least) the subquery should return 1 (one) row with NULL in it. The cardinality of the result set of the subquery is 1 and, therefore, EXISTS should evaluate to TRUE.

Please note that NULL is not compared with anything here, as the other poster suggested, and different empty sets are not compared either, as far as I can see.

If that is not what you were asking please elaborate. Thanks.


Regards,

Victor



     
  <Prev Next>   <<First <Prev Next> Last>>  
 
 
 
 
 
 
 
 
  
  Top Home Privacy Feedback  
 
 
Copyright for the TeradataForum (TDATA-L), Manta BlueSky    
Copyright 2016 - All Rights Reserved    
Last Modified: 27 Dec 2016