Would that do the trick?
Not sure what this means, so I'l read about joining in SQL. I've heard of it, but never used it.
almost but you need to join the C table. You may have only heard of joins but you are already using them
AND B.solution_id = A.solution_id
is a join (implicit)
so join the C table also to A
I recommend some reading up a bit of sql and database design. will save time later on not making mistakes early on in your schema.