Database design is the process of specifying the logical and/or physical parts of a database. The goal of database design is to make a representation of some "universe of discourse" - the types of facts, business rules and other requirements that the database is intended to model.

learn more… | top users | synonyms

0
votes
1answer
29 views

Enum in database vs. mapping attribute to integer via ini-file? [closed]

I'm writing a web-application with PHP with a friend. We have a few data-types with 3-10 different values each. I included them in the MySQL-database as enums with all of the different values ...
2
votes
0answers
9 views

Design database for real estate property management? [migrated]

I have design this database diagram to real estate property management just I want to see if I get it right especially the relation between properties and finances because I made it one(property) to ...
2
votes
2answers
58 views

A query on Hibernate database design

I am writing a simple web application where I have a User entity and set of pre-defined questions to be answered by the User. The answers provided by the users for these questions would need to be ...
2
votes
1answer
59 views

Normalization: is it done well? [closed]

I am creating game review database. I am new at this, but I am trying my best. Little bit about database: The system is simple, the user will fill out a form, where they will insert their name, email ...
2
votes
3answers
156 views

choice of tables for a project to handle attendance

I'm working on my project in php [handling students attendance system]. I have a list of students along with their id[jntuno] and I need to create a database in mysql for storing the daily attendance ...
4
votes
1answer
102 views

Critique my Stack Overflow schema

I'm learning DB design. How would you change the following schema which tries to replicate Stack Overflow's functionality: create_table "questions", :force => true do |t| t.text ...
0
votes
1answer
115 views

Review database schema [closed]

The database is for a website showcasing advertising agencies. "Premium" paid accounts will have a profile page detailing the agency, a client page, and a creative portfolio with their work. Basic ...
3
votes
2answers
77 views

How to design DAOs that handle composite objects?

Suppose I have following elementary DTOs, each DTO corresponding to a database table: class Event { String name } class Player { String name } DAOs for elementary DTOs: class PlayerDao { ...
5
votes
2answers
2k views

Strategy to create audit trails for a SQL database

I wish to create audit trails for specific tables and columns in my database, and document who made the change, when it was made, and what the change was. To do so, I will create the following ...
2
votes
1answer
168 views

Keeping track of people's relationships in MySQL using a people relation table?

I am trying to track relationships among people. I came up with my own solution, but wondering if there might be another way or better way of doing this. To keep it simplified, I'll post just the bare ...
1
vote
1answer
83 views

SQL vs MongoDB (TCG collection managment) [closed]

I'm designing a web application to help some friends and I manage our card collection. A relational database makes sense to me, so that was my first instinct. The basic schema would like something ...
1
vote
1answer
89 views

Designing price calculation methods model (needs review)

I'm building an application for a bonded-warehouse. They have services calculated by Unit price like "Container surveillance duty = containers number x storage days x unit price" and they have ...
-1
votes
1answer
75 views

SQL Avoiding dynamic tables [closed]

I have following problem: I have program, that connects to IRC server, join several channels and for each user on it, count amount of messages. I have to put all this into MySql. So, naive solution ...
2
votes
2answers
147 views

Database design improvement

I am doing a database design I want to create a database with information of employees, their jobs, salaries and projects I want to keep information of the cost of a project (real value of project ...
2
votes
2answers
293 views

My database schema [closed]

I'm not sure if this would be okay to put here since it doesn't have code to look at, but this is my database I'm trying to create for an online firearm store. I'm new to database design and ...
3
votes
1answer
232 views

Is my ERD design for “Adding Friends Capability” is good enough? [closed]

I have a school project to create a simple networking site, And I want to know if my database design is good. I'm open for any suggestions to improve my design thanks!
10
votes
3answers
145 views

Object database schema, should i split my tables?

I have a database schema for a game to hold save files where some tables have a one-to-one relationship to Classes. And i was wondering if i should split up some tables. Example troop_class table. It ...
4
votes
1answer
152 views

My first implementation of mongoDB

I'm new to Code Review, my assumption is that it is a place I can get feedback on working code that I've built, I hope that is right. This is my first implementation of mongoDB, much much more to ...
2
votes
3answers
123 views

Referential MySql Design

How does this look? It has been over a year since my database concepts class and I have never worked with MySql. I have chosen InnoDB as my engine because of foreign key support using UTF-8 based on ...
1
vote
1answer
114 views

MySQL database with foreign key support

A modified review request has been made here. Can I please have someone review this simple database design below and tell me if this is the correct way to achieve what I want to do? What I am ...
1
vote
2answers
407 views

Is this the right db design for the most flexible and modular CMS with user management in CakePHP?

I would like to ask you guys if you could review my database design: I think it is quite self-explanatory, but to be absolutely clear: My goal is to make an application which has a super flexible ...
3
votes
1answer
555 views

Schema for Google Docs-like Sharing

I want to allow users to share documents (and other stuff) in a database-driven application. I have designed the following schema to allow for this (postgresql). Some of the tables like Party are ...
1
vote
1answer
253 views

Is it proper TPT Inheritance

I have following model and database created using Entity Framework. Is it proper TPT Inheritance? Is it possible to make the base class as abstract? Model Database CODE namespace LijosEF { ...
0
votes
1answer
1k views

Data Structure for Categories and SubCategories

I have this relationship: Many Objects to One Category One Category to Many SubCategories I am looking for the best way to store this in my Relational Database? Here were some of the ways I was ...
1
vote
1answer
154 views

Can't Spot the error? mySQL create table [closed]

Currently following a couple tutorials and simply can't locate the error preventing the creation of the table. I've even done this before. So simple! Yes, I could manually add the table but I'd ...
5
votes
2answers
598 views

Database table with a single row - bad idea? [closed]

I have a "virtual scratchpad" Rails app that has pages (analogous to a piece of scratch paper), and each page has_many :notes (analogous to the notes that you'd write on that paper). I want to count ...
3
votes
2answers
241 views

A database schema for articles and their revisions [closed]

I'm designing a super simple web application for creating articles. All articles on this site can be edited by different people and each edit is a revision. Using an RDBMS, this is my schema: ...
3
votes
1answer
367 views

Please review my database design for an online organization tool

The problem I'm trying to solve. I'm a big fan of David Allen's Getting Things Done, but the myriad software tools and sites I've tried haven't impressed me that much. That's why I've decided to ...
0
votes
1answer
114 views

Package Manager in Python

I've written a package manager for OS X in order to improve my Python skills. This is the second programming project I've ever worked on, so I do not expect it to be great, or anything, but I would ...
6
votes
6answers
426 views

Database design review - tracking of many statuses [closed]

I have designed the following database for a small project. Please review and leave feedback. The main problem I'm having is to keep tracking of many statuses. The user wants to know the status of ...
0
votes
1answer
107 views

SQL table normalization upto what extent [closed]

I have an asp.net form which contains like 5 tabs and each tab has at least 15 fields in it. They all belong to one record so for the sake of simplicity lets call the PK as RecordId. Now i have 2 ...
2
votes
2answers
2k views

Need advice for my simple shopping cart's database structure [closed]

I’m trying to make a simple shopping cart application in PHP and am unsure of how to structure the database. I believe there are three tables that I need (but I could be wrong!): 1. products table ...
2
votes
1answer
92 views

MySQL query: blog entry has comments or not

How expensive is this query? Lets say for example if I don't have a field called total_comments in my blog table. All I want to know is the blog has comments or not. SELECT EXISTS (SELECT true FROM ...
3
votes
3answers
121 views

Is this DB design normalized? [closed]

Is this normalized properly? Is there a more efficient way to design this DB? A Profile can have unlimited albums, any user can create an album from anyone's videos. An album may contain many videos, ...
2
votes
1answer
234 views

Database Design Review (Part III) [closed]

I've been thinking a bit more on my database design sense database-design-review database-design-review-part-ii I think I've settled on a database design based on the 2 reviews so I shouldn't be ...
0
votes
1answer
127 views

Database Design Review (Part II) [closed]

I've been thinking a bit more on my database design sense this post. The general idea is I'de like to create a generic database that can store information on any number of subject, similar to a wiki, ...
2
votes
2answers
817 views

Relationship design for auto parts store database

I'm creating a design database for an autoparts store (this is a project school). For the moment, I'm not sure if the relationship model especially in MODEL, MAKE, BRAND is correct (I really have no ...
1
vote
1answer
105 views

feedback wanted on Elixir db model

I have designed this model which is very flexible. For example, you can create asset types, assets and combinations of them infinitely. It is the front end to a Python Pyramid website, so all the ...
2
votes
1answer
186 views

Review my database structure and tell me your suggestions on it

I would like your thoughts on my database structure. I am kind of a rookie but I am trying. All of your suggestions, alternatives, ideas, additions are welcome. Thank you. CREATE TABLE `buy` ( ...
2
votes
2answers
852 views

review ERD for website [closed]

I am a noob and would like some help with the erd for a website I am building. There are roles for the users that participate in the board. I'm not sure I have that down correctly. I realize that I ...
3
votes
2answers
307 views

Creating contact tables [closed]

I have a module in my college project for managing Contacts. I'm confused on how to design the contact table. One contact can have multiple email, mobile, website addresses. So I have created two ...
4
votes
5answers
2k views

Database schema for a school

Here is the database query needed to create the database: create table Area ( AreaId int primary key identity(1,1), Name nvarchar(64) not null ) create table Level ( LevelId int primary key ...
3
votes
2answers
266 views

database design for an online learning application

It is an online learning application with different types of learnable items, that different users learn. The users learn by spaced repetition (once right, wait a couple days, ask again), success is ...
7
votes
5answers
9k views

Database class using PDO

The point of this question What about this piece of code? I'm actually using it while developing a simple application and it seems to cover all my needs. Also it uses PDO so that we don't really have ...
21
votes
6answers
2k views

Can you peer review my database design for a school system?

This system has to manage students, teachers, staff and grading. This is for production and is not a school assignment. As such, please let me know if I can improve on any aspect. :) My main concern ...