Left Outer Join not returning all records from primary table
When I do a left outer join, I expect to get all the records that the query would return prior to adding the joined table, but it is only returning records that match the joined table (i.e: no record for '092387' exists in table 'documentation', so I just want null returned for 'filename' field for that record.) What am I doing wrong? mysql> select documentation_reference.ref_docnumber , documentation.filename from documentation_reference left outer join documentation on ref_docnumber=documentation.docnumber where documentation_reference.docnumber='TP-036' and documentation.status!=3; +-------