Depends on how your data is set up, but if you have rows with both a category and a subcategory, you can use a template column to join the two together and then use that for a relation to your pros.
I split category and subcategory into two separate tables as I eventually want to add additional tags to the subcategory for navigation and discovery purposes. So maybe I need three tables?
In my example I would have “…wood flooring, tile, etc.”
What I’m not certain of is which table to relate it to since there’s a hierarchy to the taxonomy.
So do I relate to the lowest level and then lookup my way to the top?
The way I would probably do it is to have a single column Category table with just a list of categories.
Home Improvement
Then have a subcategory table that lists subcategory in one column, as well as it’s associated category in another column.
Home Improvement | Flooring
I’m assuming you have a third Pros table that has a category column and a subcategory column along with the pro name
Home Improvement | Flooring | Contractor A
In the Category table you can create a relation linking the category name to the category name in the Subcategory table.
In both the Subcategory table and the Pro tables, you can create a template column that joins the Category and Subcategory columns together to end up with something like this.
Home Improvement-Flooring
Using the template column in the Subcategory table, you can create a relation linking the template column to the template column in the Pros table.
If I’m way off, then you’ll need to provide more details and screenshots describing your data structure and what exactly you are trying to do.
I like the use of the template columns, I’ve been struggling to figure out how to display the association between Cat > Subcat so this is super helpful.