Unanswered: How to use a subquery/join with three tables in mysql?
I have three tables as shown above. testplan table stores all the cases executions tables store execution related data builds table stores builds related data
I want to retrive data from these table in such a way that it should display all rows from testplan table, for each row if any execution is there from execution's table and only the build names from builds tables.
I used following query
b.name AS Build_name,
e.status AS status,
from testplan tptcv
inner join executions e on tptcv.tcversion_id=e.tcversion_id and tptcv.platform_id=e.platform_id and tptcv.testplan_id=e.testplan_id
inner join builds b on tptcv.testplan_id=b.testplan_id
This query doesn't giving me the expected result as per the row count needed compare to rows in testplan table.
Result should show all rows from testplan table and matching data from executions and builds table. For non-matching value it should display NULL values