# Market place product, categories and sub categories

**URL:** <https://forum.bubble.io/t/market-place-product-categories-and-sub-categories/154613>\
**Category:** Database\
**Created:** [June 7, 2021, 8:10am UTC](https://forum.bubble.io/t/market-place-product-categories-and-sub-categories/154613 "2021-06-07T08:10:00Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![david48](https://avatars.discourse-cdn.com/v4/letter/d/85e7bf/32.png) [@david48](https://forum.bubble.io/u/david48)\
**Post date:** [June 7, 2021, 8:10am UTC](https://forum.bubble.io/t/market-place-product-categories-and-sub-categories/154613/1 "2021-06-07T08:10:01Z")

</div>

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.

E.g

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

 ![app-Bubble-Editor](https://us1.discourse-cdn.com/bubble/original/3X/3/a/3a33c53a170b18746f78dae1f59da65ddff298de.png)  
 ![app-Bubble-Editor1](https://us1.discourse-cdn.com/bubble/original/3X/4/9/493805a1e3f2c36cecbdc6b8544f6b722188191e.png)  
 ![app-Bubble-Editor2](https://us1.discourse-cdn.com/bubble/original/3X/d/c/dc5acb428817e23f664b2ebf74f56bc6283ea378.png)

The form sellers would fill out

 ![app-Bubble-Editor3](https://us1.discourse-cdn.com/bubble/original/3X/5/d/5d398fee1e1b197908781fb4e3632c0e8d72e88a.png)

The repeating group i would use to do a search

 ![app-Bubble-Editor4](https://us1.discourse-cdn.com/bubble/original/3X/c/5/c521601c6246ac216bd4f3b9bc62c0e586c0d1b5.png)

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

Thanks

---

<div class="post-metadata">

**Author:** ![Valeria2](https://avatars.discourse-cdn.com/v4/letter/v/71c47a/32.png) [@Valeria2](https://forum.bubble.io/u/Valeria2)\
**Post date:** [March 25, 2023, 10:13am UTC](https://forum.bubble.io/t/market-place-product-categories-and-sub-categories/154613/2 "2023-03-25T10:13:43Z")

</div>

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?

---

<div class="post-metadata">

**Author:** ![NoCodeDataArtisan](https://sea1.discourse-cdn.com/bubble/user_avatar/forum.bubble.io/nocodedataartisan/32/170886_2.png) [@NoCodeDataArtisan](https://forum.bubble.io/u/NoCodeDataArtisan)\
**Post date:** [March 25, 2023, 12:46pm UTC](https://forum.bubble.io/t/market-place-product-categories-and-sub-categories/154613/3 "2023-03-25T12:46:57Z")

</div>

Hello,  
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.
