I have a idea of a database structure but am unabl...
# orm-help
d
I have a idea of a database structure but am unable to get a grasp on the correct layout.
Copy code
Server_type_1:
- title
- description
- name
- id
- custom thing 1
- custom thing 2 
- custom thing x

Server_type_2:
- title
- description
- name
- id
- custom thing 1
- custom thing 2 
- custom thing x
Currently, using postgresql, I'm not understanding how I could load all these options under one URL with NextJS/Prisma. Since I have to specify a table like
Server_type_1
for example?
o
You could add a query param to the url to distinguish between them.
n
Are you having an issue in designing your database schema? Or designing your API structure?
Do you want to pass these values to NextJS API Routes?
d
I'm newish to the whole concept, but the goal is like subreddits on reddit, but each subreddit has customisations
So I can't have 1 massive table which has many, many columns which are useless 95% of the time. So some way of loading the custom column info depending on the initial link.
So all data loads via /r/ for example, but custom content loads depending on the table, e.g. Server_type_1 or Server_type_2
n
Have you started with some sort of database schema?
d
Nothing as of yet, since I think that's the focus of how this would work best
https://www.reddit.com/r/Database/comments/uycng9/database_design_like_reddit_but_each_subreddit/ Here's a post I made to Reddit, had a rough go at what one of the comments said.