Re: brain cramp or bug: inner join returns rows w/null
Date: Mon, 24 May 2004 18:57:02 -0400
Message-ID: <40b27e1c$1_4_at_corp.newsgroups.com>
Robert,
Brain cramp.
An inner join is essentially a cartesian product of the 2 tables with
filtering based on your "where" clause.
The number of rows returned could have been as much as 20,000,000.
The nulls that you are refering to are fine, since that's not one of the
columns with which you joined the tables.
Regards... Jon
Jon Armstrong
"robert" <gnuoytr_at_rcn.com> wrote in message
news:da3c2186.0405241314.336dec01_at_posting.google.com...
-----= Posted via Newsfeeds.Com, Uncensored Usenet News =-----
> running 8.1.7 server, 8.1.6 client.
>
> i *thought* inner join should not return nulls, but not only that,
> but i get way more rows than i'm expecting.
>
> assume:
>
> order table:
> order_number
>
> order_line table:
> order_number
> order_line_number
> value
>
> assume 1,000 order rows, 20,000 order_line rows all have an
> order_number and value.
>
> the following:
>
> select value from order_line, order
> where order_line.order_number = order.order_number
>
> returns rows with value = null
>
> ??
>
> not only that, but the number of returned rows is app 65,000.
>
> brain cramp or bug???
>
> thanks,
> robert