I have a basic level of SQL understanding, hence needing help and thanks in advance to those who reply.
I have 2 tables, one table contains Headings and Options that can be selected under those headings. The other table links to the actual data references of that table to reference the heading name and option.
I am trying to perform a SQL query to join these tables, then reference the parent/child ID’s in one table to pull the heading+selected option from the other table, but all I get back is the ID numbers. I’ve created a image that should explain what I’m trying to get back as a result.. and failing at badly!
This image here will explain:

NOTE – Above, where I say not 18 and 20, I can make my result show the ID numbers.. but not the correct info from the Parent title and Child title. (Server Support – Site Visits Chargable)
This is where I’ve gotten to with the SQL:
SELECT custom_def_organizations.title
FROM custom_data_organizations
INNER JOIN organizations
ON custom_data_organizations.organization_id = organizations.id
INNER JOIN custom_def_organizations
ON custom_def_organizations.parent_id = custom_data_organizations.root_field_id
AND custom_def_organizations.id = custom_data_organizations.field_id
First query to join parent and child, without custom_data_organization but using the implied hierarchy:
This will return:
Now to fetch the other info:
This will return:
The same concept but with custom_data_organizations driving the JOIN:
This will return: