I'm stumped. I have created the attached MySQL statement that works perfectly as long as the inner join is successful. The result is intended to connect a parent and child table on the cpt field. The majority of the data comes from the parent table and only description of the matching cpt field comes from the child table.
Here's my problem: Using my statement as written, if there is not a match, the parent record is not selected. What I would like to happen is to select the parent record and substitute the description that would have come from the child table with a descriptor like "NO CODE DESCRIPTION AVAILABLE." Can this be done? If so, can someone help me with the code to insert that will make the MySql statement do what I need?
INNER JOIN cpt ON phy_sec.cpt=cpt.cpt
WHERE phy_sec.inum = '".$inum."' ";