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

learn more… | top users | synonyms

1
vote
0answers
19 views

Database Design: Mutability vs Historical Data

Imagine a software for theater owners. You can accept reservations for the different cinema halls. Each hall has a different number of seats. Say the owner wants to know how many people visited the ...
2
votes
2answers
102 views

Should I use relational or noSQL databases for this problem

I'm working on a project where one part is to save data of different people. A typical person might have the following structure: Email: Multiple values possible City: Multiple values possible ...
2
votes
1answer
39 views

How to represent an optional-to-optional relationship in a database

I have two types of users: a CRM user and a system user. We have a record of every CRM user, thanks to a nightly sync that we run (so we don't have to hit the CRM API every time). We have system users ...
0
votes
1answer
36 views

user verification value - where to store [closed]

Quick question as relates to database. Where would you store the value of "UserVerified"? (The one that occurs after the user has checked his email and clicked on the "Verify" link with the hash ...
0
votes
2answers
54 views

How to Design Database with User-Contributed Content

I'm building an application where there are different "Locations". There are Stores, Bars, Schools, and Churches (and so on) all of which are geocoded and defined by existing data sets. While not ...
-1
votes
1answer
99 views

Best way to track 200 boxes [closed]

I have a php/mysql application that needs to track a simple on or off setting for 200 boxes. I use it for a fundraising application. Basically there are 200 buttons. A user selects a button numbered ...
0
votes
1answer
18 views

Looking for advice for the following MS SQL Schema

We currently have the following SQL Schema: Projects Budgets BudgetTabs BudgetSections BudgetTasks BudgetTaskDetails ...
1
vote
1answer
20 views

Proper tree NoSQL structure with focus on full-text searching

I developing an app with tree(folder-file) structure, on which I should perform full-text searches with MongoDB. I did a research on the best tree structure practices and found this great article, but ...
0
votes
4answers
89 views

Is there an accepted design pattern for storing a few global variables in a NoSQL database?

I'm wanting to create an admin dashboard for my app, and to show new events there. In order to know which events are new, I'll need to store at least one extra datapoint to the server: the last date ...
3
votes
2answers
81 views

Integrating Holidays and Attendance in an HR Management System

I'm developing a small HRMS system for my company, and am currently thinking of how to integrate attendance and holidays. We currently have an in_time/out_time based daily attendance system, but the ...
2
votes
3answers
153 views

What are the advantages/disadvantages of creating a new set of tables for each user?

I'm working/playing on an app where individual users' data will be completely independent from each other. Of course, there will be common tables for other parts of the app (e.g. "users"), but for the ...
0
votes
1answer
60 views

Would it make sense to have a database table with only one record for tracking site summary stats?

I'm creating a web site that deals with monetary transactions. Users can deposit funds into a wallet and use them on the site. I'd like to keep track of some stats for the web site, like revenue and ...
2
votes
2answers
104 views

Designing a system to archive databases with referential integrity

I have a very large Oracle database, with many many tables and millions of rows. I need to delete some of the rows end-to-end. By end-to-end, I mean, if I want to delete a row from a table then I must ...
0
votes
0answers
23 views

Managing allocation calendars for an employee set [duplicate]

IN view of creating a MIS (Management Information System) one architectural/design issue that's confronting us is managing allocation for set of employees. Scenario: Employees get allocated to ...
0
votes
1answer
40 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
2answers
41 views

Representing category splits in a personal finance database

I'm working on developing a personal finance applications (e.g. Quicken/Mint.com/etc..). I plan to store the data in a SQLite database. I'm stuck trying to determine how I want to represent splits in ...
13
votes
3answers
2k views

Database schema for a ToDo list

I am trying to make a very simple todo list application with PHP, MySQL, Jquery templating and JSON... However, my schema seems to complicate things in JSON. What's the best way to do it? A new ...
2
votes
1answer
37 views

Architecture: Storing all properties as JsonProperty in NDB?

I am storing the data for my app in Google's NDB, but am confused as to what architecture to use. The app data is mostly text based, but has some non-text properties like DateTimeProperty, ...
6
votes
4answers
375 views

Heterogeneous Associations - Data Modeling When an Object that Must Relate to One of Many Classes

Suppose you have 3 classes: ClassA, ClassB and ClassC. Now suppose you have a class Message. You want a one-to-many relationship between each one of those three classes and the Message. The goal is ...
1
vote
3answers
105 views

Database design: 4 types of users but have different functionality , separate or one table?

I have 4 types of users: Admins , normal user , company , service provider admins and normal user share some attributes (id .first name ,last name ,phone ,mail) company and service provider share ...
0
votes
1answer
64 views

RDBMS (MySQL) logic question. How to join multiple “FRIENDS”

so this is a logic question as to creating the proper relationships in a MySQL database. What logic would you choose for the following scenario? This is a back-end for an app where people can have ...
1
vote
1answer
63 views

How to associate both a collection and one item of this collection to an entity

I'm working on a project in which I have an entity, we may call Users and another entity Address. I want to define the entity User in a way that an user would have a collection of addresses ...
5
votes
2answers
245 views

Database Normalisation - stuck with “categories”

Context: I'm working on a database of museums and Categories will be one way the user will be able to search. e.g click on "Music" and a list of music related museums turn up. Pretty simple. ...
3
votes
1answer
202 views

How to store a potentially large amount of optional properties of objects?

I'm using Entity Framework Code First with ASP.NET MVC. This handles my database design based on the domain models within my application. As it stands, the engine I'm writing will have a website ...
2
votes
2answers
94 views

Database Design for Inheritance

In my project I have an object Player (attr example: pl_id, pl_data1) that is one of these types: Its GoalKeeper (attr example: gk_data1) OR Defender (attr example: df_data1) OR Forward (attr ...
0
votes
1answer
32 views

is there anything called logical schema and the conceptual schema of a database table?

i want to know whether there is anything called logical schema and the conceptual schema of database table. if so what is it.i searched lot of places for this specific two words, but did not find ...
0
votes
2answers
41 views

combining user data from user table and user_profile table to just one table [closed]

We are using two table to manage user data. A user table that has a username, email, password. Then a user profile that has first name, last name, bio, etc. Due to some other requirements it has been ...
1
vote
0answers
54 views

Best approach for displaying a price from a product according the “setup”? [Designing the DB table and relations]

I'm basically building a reseller website, in which people can buy (users) from a predefined product list and sell them at a higher price (clients). I will show you some images to explain better ...
2
votes
3answers
206 views

Best approach for an online store which changes its product’s price over time? [Designing the DB Table]

I am currently creating a website which will allow people to buy consumer products (deodorant, shampoo, toothpastes, etc…) from a store. Those products tend to change price and other details twice per ...
1
vote
1answer
89 views

Representing list of polymophic objects in db

Let's suppose I have a list of derived objects from some base: class Circle : public Shape; class Rectangle : public Shape; There is object, which has vector of Shape * as member variable: class ...
0
votes
2answers
84 views

Optimal Database design for 3-way relationship

All right, I know this sounds complicated, but all relationships are, lemme clarify. Well, I have three entities in my database which are tied to each other in a string of relationships, the app is ...
1
vote
2answers
79 views

How to minimize networking cost of distributed game database?

We've been working on a networked online game project which will run in near future and looking for a satisfying solution for our distributed game database. We didn't take networking costs into ...
0
votes
0answers
43 views

Best solution for future maintenance of a website with hardcoded ids, custom CMS using bad database design

Recently I was put into a position of a tech-lead on a very interesting project that I have been partially working for two years. This project carries a lot of legacy stuff with it even though we try ...
-1
votes
1answer
58 views

Naming a recursive association entity [closed]

For my current project, I need to create a database table to store a recursive association. I've done a lot of searching and have read answers on questions, such as Naming convention for associative ...
1
vote
1answer
173 views

Data model for persisting queries to database

I have been asked to build what is essentially a query builder for a reporting application. The variety of objects to query, potential modifiers, number of conditions, and so forth to be reported on ...
0
votes
1answer
50 views

Multi-lingual support implementation in a website

I'm developing a Multi-lingual website which is being developed in custom PHP and using MySql. To implement the multi-language support, I've come to think of this approach (steps below). Please ...
1
vote
5answers
141 views

Database design with performance issue and use of views

I am designing database for a school system. I am having to create a lot of tables and a lot of link tables to maintain a structure in the system. I am trying to maintain foreign integrity and trying ...
1
vote
1answer
88 views

How to save appointments in database?

There are 2 entities. One is admin. The task of admin is to define slots for appointments which will be taken by applicants. The admin will choose a default time for the appointments like 10am to ...
4
votes
3answers
327 views

Is MongoDB appropriate for systems that will be likely to change?

I've been using MongoDb (mainly with Meteor) and for me, it has been a great way to mock up prototypes and proof of concepts quickly. I'm just wondering, after building the initial product, if your ...
0
votes
1answer
29 views

Storing and presenting custom table data

I have a web site upon which I want to provide users the ability to create tables of data. These tables will come from a predefined list of table definitions of which I will be adding to myself. This ...
0
votes
1answer
93 views

Single database, multiple system dependency

Consider an environment where we have a single, core database, with many separate systems using this one database. This leads to all of these systems have a common dependency, which ultimately ...
0
votes
1answer
53 views

Does this Relational Database Model make sense?

Here is a flat version of my datamodel. It is sensor readings for various data acquisition equipment. ...
3
votes
2answers
169 views

Would these two scenarios be good candidates for a NoSQL database?

I've checked a few other threads around the topic and search around, I am wondering if someone can give me a clear direction as to why should I consider NoSQL and which one (since there are quite a ...
0
votes
0answers
27 views

Implementing multiple tables for the same entity due to processing power on Client apps

I reached a design/architectural issue on the large application I'm working on, at the point of writing possibles solutions on a chalkboard. Our product consist of a client-server information system ...
0
votes
0answers
31 views

Product Configuration with conditional options

Suppose you need to create a website where you can choose a Widget, and then configure all of the various options to go with that widget. The options have many interactions. For example, if you ...
1
vote
1answer
94 views

Entity-Attribute-Value table vs single table for storage of posts, events and pages

I am trying to decide whether to just use individual tables with more fields for storing posts, pages and events or using tables with basic fields plus having EAV tables as well for fields that are ...
1
vote
2answers
67 views

Patterns for undo in multi-user applications on relational data

I want to build a web application that will allow multiple users to collaboratively populate the contents of a fairly conventional relational database. (The database will have a fixed schema, which is ...
0
votes
0answers
48 views

Extending database model of ORM in subproject

I have a maven project which contains some entities which are stored in a database. The purpose of this project is to manage personal information, users, locations, etc. This project can work on its ...
0
votes
0answers
24 views

how to reduce or stop duplication of relation's entry in treeview

I want to create tree-view for display or show family member's relation. For this I created 3 tables i.e following. familyDetails->[f_id,fname,lname] relations -> [r_id,relation] .....//e.g ...
0
votes
2answers
56 views

Data model - inheritance

I just started working on a project where I am trying to implement some backend logic which includes creating a data model for the given problem. Here is a problem I came across and I am curious what ...