Re: Results question
Stuart, Comparing anything to null, including another null, will always return false. This is why you query is returning no results when the clauses that reference columns that contain nulls are included. Regards, Eric "Stuart Felenstein" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > I have a select, from, where, query set up. > There are a number of "inner joins" in it as well. > Now what I noticed is if there are some null fields in > the records, nothing will get returned. If I remove > those particular joins (where the NULLS are), the > record is returned. > > Does this sounds like a join issue ? The tables that > are joined are "interpretive" tables. Meaning I store > a 1 for Alabama in the main table. The States table I > join has the 1 and then the associate label. > > Stuart > > > -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Results question
Stuart Felenstein wrote: I have a select, from, where, query set up. There are a number of "inner joins" in it as well. Now what I noticed is if there are some null fields in the records, nothing will get returned. If I remove those particular joins (where the NULLS are), the record is returned. Does this sounds like a join issue ? The tables that are joined are "interpretive" tables. Meaning I store a 1 for Alabama in the main table. The States table I join has the 1 and then the associate label. Stuart You need LEFT JOIN to get results for the lines that contain NULL values in the joined table. http://dev.mysql.com/doc/mysql/en/JOIN.html HTH, Wolfram -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Results question
I have a select, from, where, query set up. There are a number of "inner joins" in it as well. Now what I noticed is if there are some null fields in the records, nothing will get returned. If I remove those particular joins (where the NULLS are), the record is returned. Does this sounds like a join issue ? The tables that are joined are "interpretive" tables. Meaning I store a 1 for Alabama in the main table. The States table I join has the 1 and then the associate label. Stuart -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]