Skip to main content

Questions tagged [database-design]

For questions about structuring the data within a database. How to lay out tables, whether to use a relational DB or not, etc.

3 votes
2 answers
1k views

Best way to structure many-to-one allocation of users to projects in NoSQL

I apologise if this is a bit of a stupid or broad question, but I'd like some general feedback please! Say I have this DB structure for users (in Mongo/JS, but really it's all pseudocode- and the IDs ...
0 votes
0 answers
67 views

How to restructure a schema in order to support conditional (one of two tables) relations

I've been stuck on this for a while now so I decided to ask for some help. My SetTemplate needs to EITHER be connected directly to exerciseTemplate OR connected to exerciseTemplate through a ...
1 vote
2 answers
72 views

How to design user-defined ordering of items?

I've got a site (here) that lets users publish labs. I'm looking at adding a feature where users can customise the order that their labs appear in. To be clear, I mean that they can manually control ...
2 votes
1 answer
681 views

What would the database schema look like for a Entity Component System architecture of web app?

I found previous SE questions like this. I'm familiar with the typical RDBMS backed MVC web app framework. To illustrate what I am thinking of, let's use the examples of Bunny and Carrot from this [...
1 vote
2 answers
101 views

Linking records through multiple tables?

I'm writing a game server. Similar to the Sims. Players can own furniture items they purchase from the catalog. There can also be rooms. Players can be in a room. A room can have furniture items of ...
2 votes
1 answer
149 views

What is an optimal system design for tracking product views per user that is scalable?

I have a web application that contains products and users. There are 10,000+ products and 100,000+ users to give a sense of the scale that's required. For some application specific reasons, I need to ...
1 vote
1 answer
89 views

Does it make sense to use a graph database (Neo4j) for a diagramming app?

I am developing a diagramming application and want to optimize operations with the Nodes and Relations of the diagram. Currently, I am using a relational database with tables for diagrams and nodes. ...
0 votes
2 answers
193 views

Advice for database design and approach

I ask this to learn from experienced DB designers/architects. I need a high-level overview, I'm not interested in the specific tools for now. Rather, I'd like opinions on how you would approach this ...
2 votes
1 answer
182 views

Designing a flexible and comprehensive restaurant menu database schema?

I am working on developing a MySQL database schema for a restaurant menu system inspired by platforms like DoorDash, UberEats, and Yelp. My aim is to design a schema that is flexible and can handle ...
-1 votes
1 answer
50 views

Ensuring unique indexes on nosql datastores [closed]

I am building a User Service. User would be able to register with emailId or phone no. Upon successful registration, they can choose a username (which should be unique) It is easy to do on SQL ...
-1 votes
2 answers
106 views

Best Practices for Storing Operational Hours Extending Past Midnight in MySQL

I'm building a PHP application to manage business operating hours, including cases where the closing time extends past midnight. I'm considering various ways to store these hours in MySQL and need ...
-1 votes
1 answer
153 views

Would it be a good design to have multiple repositories for one entity?

I am working on a project. I have designed the codebase all the way from the scratch. Basic thing is the project is divided in individual modules. The modules represent one complete part of a business ...
0 votes
1 answer
472 views

Regarding data modeling in a NoSQL use case

I am reading the following link to learn about system designs of various systems. (This is a paid link, I am attaching all explanations below.) In an attempt to explain the system design of Instagram ...
0 votes
0 answers
39 views

Need advice on approaches to saving data

The following code(JSFiddle here) is a grid-based code where I'm performing the following steps: I’m moving blue boxes from left to right (on the grid) after clicking Move Text Content! button. Here ...
0 votes
1 answer
62 views

Database Modeling for Application with Many Integrations

I’m working on an application that requires many 3rd-party integrations. I’m using Postgres to store these API responses but am having trouble for a number of reasons. These objects are frequently ...

15 30 50 per page
1
2 3 4 5
89