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
3 views

need a code to implement connection pooling through jdbc using oracle databse

import java.util.Hashtable; import javax.naming.; import javax.naming.directory.; public class OracleDataSourceRegisterJNDI { public static void main(String[] args) { try { // Set up ...
-1
votes
1answer
39 views

Naming a recursive association entity [on hold]

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
161 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
3answers
113 views

Are Data Warehouses bespoke products that are tailored towards the specific needs of one single organisation?

Are Data Warehouses bespoke projects that are developed to meet the needs of a specific organisation or can you buy off the shelf products that would meet the needs of many organisations? I am ...
0
votes
2answers
61 views

Help with database design with a strict and structured subset of clinical data

I'm developing an application to keep some of the data in chronic patients, the data came from a very strict subset of data, vital signs, exams, ecc. On a first glance I thought to create a Patient ...
0
votes
1answer
40 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
1answer
132 views

Design Application to “Actively” Invite Users (pretend they have privileges)

I am designing an application where users message one another privately, and may send messages to any Entity in the database (an Entity may not have a user account yet, it is a professional database). ...
4
votes
3answers
299 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 ...
1
vote
5answers
128 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
78 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
4answers
495 views

In an online questionnaire, what is a best way to design a database for keeping track of users all attempts?

We have a web app where users can take online exams. Exam admin will create a questionnaire. A questionnaire can have many Questions. Each question is a multiple choice question (MCQ). Let's say ...
0
votes
2answers
129 views

Whats a good structure to save and retrieve locations of images?

I got a java-ee application, where I collect informations about movies. Im my backend I provide data like the name, description, genre and a random uuid. I also got lots of related files, which are ...
0
votes
1answer
169 views

Best way to implement database design for a set of entities

Lets say I have a scenario like so: I have many claims to get money from another entity and this claim has to go through two gateways. This claim is sent from an origin system and can possibly be ...
0
votes
1answer
116 views

Moving dozens of existing standalone retail sites to one central inventory database: what should I know going in? [closed]

This will be the first project of this scale that I have attempted, and the first time I have run a website at all (much less dozens) using an off-site database. In particular, I'd like to know: ...
0
votes
1answer
23 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
82 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 ...
2
votes
4answers
313 views

How should I approach this from a problem-solving point of view?

I'm currently working on a project to replace some excel worksheets. There is a lot of industry specifics that change quite often and nobody really knows how things should be but every sure enough ...
12
votes
8answers
882 views

Are there examples of non CRUD approaches?

I'm a programmer but also have worked as an archivist. As archivist it's a lot about keeping data. I often get into arguments with colleagues when it comes to operations on data. I don't like the U ...
0
votes
0answers
39 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
128 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
26 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 ...
1
vote
3answers
290 views

Keep user and user profile in different tables?

I have seen in a couple of projects that developers prefer to keep essential user info in one table (email/login, password hash, screen name) and rest of the non essential user profile in another ...
0
votes
0answers
26 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
55 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
55 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
46 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
1answer
94 views

Relationships in a Chen ERD

I am working on a Chen ERD to model our organizations merchandise. Our central entity is a Style. We have supplemental entities of Color and Season. I am defining our assortment as the ...
0
votes
2answers
54 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 ...
0
votes
0answers
23 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
41 views

Changing an int to be a string in PHP / MySQL Schema

Background I'm trying to decide the best way to manage a change in requirements. Currently when an admin is assigned to a ticket, the ticket header record is given an owner and the ownerID field is ...
1
vote
0answers
56 views

What's the canonical way to store translations of user data?

I've developed some software that allows my users to attach a blurb to some non-language specific information: Pseudocode model: item(): ID creationdate byline //Only one byline for the object ...
1
vote
2answers
68 views

Creating menu structure using DB - is that fine?

Also I have an application that basically consists of a lot of screen so user needs to navigate a lot (like go from A>B>C>D) etc. I have been thinking how to implement this (mainly hold the structure ...
1
vote
4answers
117 views

Are there any benefits in not having referential integrity keys in database?

So Referential integrity is good, but are there scenarios where not having constraints is better? For example when all the logic of relationships is kept in code? or when the database upgrade is ...
12
votes
3answers
1k views

General thought process for “How would you build this website/app” interview questions

I've collected a bunch of interview questions like "Describe how you would design a photo album application", "Describe how you would design this particular feature of this particular website" (e.g. ...
3
votes
5answers
244 views

Is it useful to keep 'definition' entities in a database vs using an enum?

In a project that I have started working on, the database has a lot of FooDefinition tables which act like an enum. It's a C# project using Entity Framework although that is not central to the ...
2
votes
2answers
76 views

Database design with “draft” version of data

The database I'm currently building is pretty traditional relational database stuff, but there is one requirement that is not clear to me how model appropriately. There are many business rules which ...
2
votes
2answers
842 views

Database model for keeping track of likes/shares/comments on blog posts over time

My goal is to keep track of the popular posts on different blog sites based on social network activity at any given time. The goal is not to simply get the most popular now, but instead find posts ...
13
votes
4answers
902 views

Is it bad practice to allow user defined fields?

Generally speaking, is it considered bad practice to allow for user created fields in a database for a webapp? For example, I am making a home inventory webapp for my wife, and she is going to want ...
2
votes
1answer
113 views

How to model a one-mandatory-of-many relationship

I have following class model that I'm quite happy with: A Whole has a special mandatory Part. Furthermore it has a collection of parts, that contains at least the mandatory part, but may contain ...
1
vote
2answers
99 views

Databases and the single responsibility principle

Can the single responsibility principle be applied to databases? relational databases I mean. I'm asking this because a typical database will have several tables and we may find something like that ...
2
votes
1answer
88 views

How to define item level permissions in a relational database

I need to model a database design to provide item level permissions to users based on the user's role access. I am using asp.net with sql server 2012 I am looking at similar experience on how ...
5
votes
1answer
2k views

Database Application Design Best Practices [duplicate]

Once upon a time it was common practice for both the business logic and database logic to be written in the same language (eg PL/SQL, Transact SQL, etc), more recently the practice is to separate the ...
0
votes
2answers
107 views

Should all foreign table references use foreign key constraints

Closely related to: Foreign key restrictions -> yes or no? I asked a question on SO and it led me to ask this here. If I'm faced with a choice of having a circular reference or just not enforcing ...
0
votes
0answers
37 views

Seeking Mongoose schema design advice

I'm having some trouble deciding on a proper way to layout some of my schemas in Mongoose. I have a User schema currently as: { name: { type: String, default: "" }, phoneNumber: {type: String, ...
2
votes
2answers
97 views

Should I be using a composite key for this table?

My database is going to store words, so the Word table is the most important. The Rhyme table lists which words a particular word perfectly rhymes with. It consists of three fields: RhymeID - primary ...
0
votes
1answer
35 views

Store Arbitrary values related to mysql record

I have created an app that manages a Data cleansing workflow. Each row imported needs to store an arbitrary number of key value pairs in addition to our standard mysql schema. The key values need to ...
0
votes
1answer
64 views

What's the best way to store options with multiple/boolean choices in an Android app?

I'm working on an Android social app which connects to a Postgresql database for up-to-date user data and is going to use lookups for dropdown menus, and these lookups will either have multiple ...
3
votes
4answers
730 views

Is this database design sound and fully normalised?

I'm creating a database to store words. The intended usage is to query the database to find a word matching a set of filters. E.g. if I wanted to find a word with < 10 letters, < 3 syllables, ...
2
votes
1answer
139 views

When deciding a Primary Key, can I use Date part of a DateTime field

I'm designing a payroll system I have designed a database with several tables and this question is related to following tables EMPLOYEE (Employee_ID [pk], Name,... etc) LOCATION (Location_ID [pk], ...
0
votes
2answers
166 views

Examples of designing a database that handles point tracking?

I'm attempting to expand my knowledge of how database designs and concepts work. I'm working on a hobby web/mobile app for practice that will challenge me. However, I am running into an issue. What ...