Market place product, categories and sub categories

Hi Guys

So i am building a fiverr type app. I need help with the structure of data base for product, categories and sub categories please.


Product - Design a website banner for wordpress
Category - Graphic Design
Sub Category - Website design

I will have 4 main predefined categories

Graphic design
Video and editing
Digital Marketing
Programming & No code

Each category will have a predefined list of sub categories E.g for graphic design below

App Design
Art & Illustratio
Gaming Design
Brochure Design
Business Cards and Letter heads
Catalog Design
Email Design
Fashion Design
Industrial & Product Design
Infographic Design
Jewellery Design
Logo & Brand Identity
Other Design
Packaging & Label Designs
Presentation Design
Print Design
Signage Design
Social Media Design
T-Shirt Design
Website Design

My current Database

The form sellers would fill out

The repeating group i would use to do a search

So a seller would fill out a form and create their product and i would like to capture the details of the category and sub category for the product that updates in the product, category and sub category data type as well.

So the product updates into the data base, but i need the sub category and category to update as well.
I think my database is not properly structured.

At the moment i am manually typing in the categories and subcategories for the accordion and dropdowns etc.

PS - and also best way to show the categories and sub categories with the above model in place - Option sets or data base?

Please can you help


1 Like

Hi there, I’ve just come across your post and got excited because i have a similar issue but then saw that u didn’t receive any replies. Small chance but could you share with me if and how you fixed it?

The correct structure of a database design depends on many factors, here I propose a solution to your question according to the information you provided and my own understanding of them.

I would like to point out that this answer is not necessarily the best solution, and for the best state of the database, we must have complete knowledge of all data types and how to use them in the app.

to choose between option set and data type, you should see if the user is going to create a category or subcategory or are they fixed?
Option sets cannot be added by the user.

Regarding the database structure, you can put the category and subcategory in single option set and separate them with the “type” field and create a relationship with itself for the parent category.

Another point is that, as much as possible, avoid creating list relationships. To search in them, the speed of the app decreases drastically.
Also, you can change many product fields to option sets.