Jonas Lind?n <[EMAIL PROTECTED]> wrote:
> Hello, I am running MySQL5.0.0 on my OpenBSD system. When I excute this
> query I get 153 hits.
> 
>    SELECT b.batch_id, b.date, b.creator, b.comments FROM cd_batch as b;
> 
> But when I add this table to the where clause i get 5831 hits
> 
>    SELECT b.batch_id, b.date, b.creator, b.comments FROM cd_batch as b,
> cd_donor as d;
> 
> Why does this happend? I thought that these two queries would return the
> exact same amout of rows. Is there something I have forgotten or is the
> debug release of 5.x.x errornous?
> 

You got in the result set cartesian product of cd_batch and cd_donor tables.


-- 
For technical support contracts, goto https://order.mysql.com/?ref=ensita
This email is sponsored by Ensita.net http://www.ensita.net/
   __  ___     ___ ____  __
  /  |/  /_ __/ __/ __ \/ /    Victoria Reznichenko
 / /|_/ / // /\ \/ /_/ / /__   [EMAIL PROTECTED]
/_/  /_/\_, /___/\___\_\___/   MySQL AB / Ensita.net
       <___/   www.mysql.com





-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to