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 (2)

0
votes
0answers
5 views

Stock table Database Design

I have to design a stock database of various products for different entities i.e. Distributor, Manager, Field Force. The relationship between the entity and the stock number of different products is ...
-1
votes
1answer
16 views

Advice books/courses about Architecture and constructing of a Database System

Please, suggest any books/papers/courses about database systems architecture and development. How they work inside. Something like this Architecture of a Database System. Any works like famous ...
0
votes
0answers
13 views

How to design a demographics database?

I have a bunch of stores. Each store has the same properties (ethnicity, marital status, income, and so on). Each of those properties has subproperties like (white, black, asian for ethnicity and ...
7
votes
3answers
721 views

Should I separate frequently updated columns?

I have a users table that contains users' information and a column named credits that is frequently updated. On index page I'm showing list of users with basic user information but I don't need ...
1
vote
2answers
206 views

avoiding unique key collisions across tables

This might be related to the idea of data warehousing, but i'm not sure, though it is extreme theory. We have a table where records get written to first, let's call it tbl_recording which looks like: ...
3
votes
1answer
133 views

Combined or separated tables: File and Message?

Is this the best approach to design this table in the purpose of sharing the file online between my customer and I, or should I separate Message table and File table or combined them together? ...
1
vote
2answers
60 views

Managing constants changes to database

Here's the deal, I'm in charge of creating a website that will host small web apps. This apps will be photo contests, creatives sentences and other similar gibberish. The deal is, since apps we'll be ...
1
vote
1answer
19 views

one table for all blob with a one to one table for metadata which link to one or many tables?

I'm going to start by saying that I'm not a DBA but i got that role in my current project so I'm doing my best. The application must be able to store files(attachments, official documents, etc) The ...
0
votes
1answer
17 views

Additional info on some rows in the table

I am trying to design an MS Access 2013 database to keep track of an inventory of items. All items have certain common properties, like name, date they were stored, location of the physical item, ...
2
votes
1answer
133 views

Peer Review of Database Design

I'm working on a movie inventory database. This is a personal side project for me. I can use what I have, but I would like to make it the best design that I can while learning more about databases and ...
0
votes
2answers
40 views

Is it ok to have 40+ columns in a table

I am currently re-designing some of DB's for a project. There is one DB in particular that is giving me a little of a headache. The idea is that for every client_id and date (client_id + date would be ...
12
votes
8answers
4k views

Professor told us to store serialized Java objects as blobs instead of defining relational tables

Instead of actually defining a tables with the correct attributes, my professor told us we could map objects to ids like this: id (int) | Serialized Object (blob) 1 10010110110 ...
-1
votes
0answers
8 views

Merge two databases, postgres [on hold]

I have two postgres databases, Consider the following situation: Database A: Table 1 Table 2 Table 3 Table 4 Table 5 Database B: Table 1 Table 2 I want to insert the same Table3, Table4, Table5 ...
1
vote
0answers
23 views

Trying to normalize a legacy database and get away from unusual XML validation

I have inherited a legacy database from around 2000 which uses XML in an unusual way to perform data validation. This database is intended to hold product data for an intricate product line when a ...
1
vote
1answer
55 views

Is it always bad to have an own table for value objects?

I know that value objects should be embedded in the table of the object they belong to but what if the value object is more than a simple object and contains many fields/columns or even sub-objects? ...
1
vote
0answers
14 views

reports on history table

Assume Trucks which travel between Cityies. I store the Cityies that a Truck has traveled to in TruckLocationHistory table, if the Truck is passing the City, State = Passed and if it gonna stays for ...
0
votes
1answer
36 views

Database Normal Form (financial statement)

I would like some advice on how to design the database for financial statement data which objectively addresses the tradeoffs between usability, performance, maintenance and adherence to normal form. ...
1
vote
1answer
171 views

Time series and gap filling

I have to choose a database server for storing big time series data. Currently I use PostgreSQL, but I've found that Vertica supports automatic gap filling for missing data and that's really nice. ...
8
votes
3answers
710 views

Why shouldn't I have one table for multiple relationships?

Assuming I have multiple relations in my database, for example Store, Employee and Sale, and I want to connect pairs with a simple binary relationship. Personally I would create tables named ...
1
vote
1answer
108 views

Proper implementation of child (derived) table PK/FK during single and multiple inheritance hard coded generalization physical data model

Below is an image of hard coded generalization UML logical model of entities. I'd like to implement these classes as tables in a physical data model. Two derived classes/entities (Class2 and ...
1
vote
1answer
82 views

representation in ms-access

I have a database in microsoft access. I want to know how to look up a singular datum from a reference table giving a dynamic set of values. Here is a representation of what I mean: I have the ...
2
votes
2answers
65 views

Associating on the ID of an association table

Sorry about the title, I couldn't find anything better. Suggestions are welcome. Say we have two tables, Suppliers and Products. The same product can come from many different suppliers, so we create ...
1
vote
2answers
27 views

Schema/Structure to handle secondary computed data

I'm trying to design a LAMP-based website for my pinball league, which plays competitive pinball every week in match play. One of the features of our league is that we convert raw scores to ...
1
vote
1answer
22 views

How to design tables for airbnb style booking system

all. My English is not very good, but I will try to describe my question as clear as possible. I want to design a airbnb(https://www.airbnb.com) style booking system, this kind of booking system ...
1
vote
1answer
30 views

Dependency preserving and lossless join decompositions

I have a relation: R = {A, B, C, D, E, F, G, H, I, J} And a set of functional dependencies: G = {AB -> C, A -> DE, B -> F, F -> GH, and D -> IJ} I ended up decomposing into two ...
0
votes
2answers
900 views

How to represent foreign key in an ER diagram?

Suppose I have a 'Transactions' table which has a column 'Customer ID' (Foreign Key) and a Customer Table having 'ID' (Primary key). How do I show the relation between the two tables and showing that ...
0
votes
1answer
29 views

schema for mysql database with 30million rows

We am building a SaaS backend for restaurants. We integrate directly with POS, so each POS keeps sending customer orders that we store in a following table in mysql. CREATE TABLE name ( `id` ...
-2
votes
0answers
21 views

Setting up a centrally based server repository (database) [closed]

I need to set up a centrally located database (server). I need to host it somewhere central so that it is accessible from all other locations of our organization. So that the data can be viewed and ...
0
votes
1answer
653 views

Storing multidimensional array in MongoDB

I am attempting to convert a large MySQL database of product information (dimensions, specifications, etc) to MongoDB for flexibility and to move away from the restriction of a column based table. I ...
3
votes
1answer
68 views

Normalized Data Store - Confused with prefixes to use

I'm designing a Staging+NDS+DDS Data Warehouse system, where an ETL is going to normalize data from [Staging] and load it into [NDS], which will hold all history. I've pretty much finished the T-SQL ...
2
votes
1answer
24 views

Database table to keep track of objects

I have a table called FoodMaker and another table called Settings. Every FoodMaker has multiple Settings. I also need a 3rd table to record what has been made, when and with what Settings. It might ...
0
votes
0answers
24 views

identifying the functional dependencies

I have been reading up on database design and I am having some difficulty constructing functional dependency diagrams from tables. I have the following table. Each salesperson is identified by a ...
2
votes
1answer
396 views

How to normalize my db schema for a quiz application?

I am putting together a quiz application. (I'm calling each quiz a "challenge") I have a "challenge" table and a "challenge_question" table which is pretty straightforward. challenge table: id ...
0
votes
1answer
125 views

Duplicate Relationships in Rails/MySQL Healthcare Application

Overview of the Application I am building a Ruby on Rails application to organize medications, using MySQL. The goal of this application is to provide dosage specific treatment recommendations, and ...
3
votes
3answers
199 views

Can't convert this type of ER diagram into SQL or relational tables

I have stumbled upon a problem during database design. Let me explain what it is all about: Contract has some simple attributes that describe him, and may have annexes and dynamics of payment. ...
0
votes
1answer
24 views

which type of database to choose for OLAP applications? [closed]

The main classification of databases are below(not sure if there are more). Relational DBMS Object Oriented DBMS Object-Relational DBMS Non Relational DBMS I want to choose a DBMS for my OLAP ...
0
votes
0answers
18 views

why this FD make 3NF?

Question like this: Consider the relation scheme ABCDEF satisfying the following functional dependencies: BC --> ADEF CD --> B E --> D BC is a key and designated as primary. Explain why the ...
0
votes
0answers
22 views

Please review and advise on the database schema design for a simple shopping cart [closed]

I'm designing a simple mp3 shopping cart, a customer needs to recharge their account before they can do any purchase. A song or album purchase amount is deducted on the customer's account credit. The ...
0
votes
0answers
45 views

Table design for optimum performance

For example let's say I have to create a table called Employee with columns EmployeeID, Name, DOB, Address, DepartmentID[FK]. So I create the table as follows with a primary key and a nonclustered ...
1
vote
2answers
134 views

How to make a better Data model

I am creating a database system using MySQL for a group in my school (a University). I am new to MySQL and its usage.I have started with the data modelling process, since this process will be the main ...
0
votes
3answers
67 views

Autoincrement Primary Key For Constants

We are having an issue that is probably due to some poor design choice or lack of understanding of how to use primary keys. We have a simple constants table CREATE TABLE IF NOT EXISTS `constants` ( ...
0
votes
3answers
418 views

Rent weekly cost database design

I have a database which contains a table BUILDING with in each row details about some building, another table BUILDING_UNIT contains rows with details about a single building unit which refers with a ...
2
votes
0answers
28 views

With SSD's and in memory tables, does a snowflake schema become preferred over a star?

With SSD's being very fast (reducing the overhead of joins), while more expensive (increasing the cost of redundancy due to de-normalization), along-with a focus on in memory tables (again reducing ...
1
vote
1answer
82 views

Reviewing relational database tables

I am building a database, but I am a little bit confused with my table relationships. I wish someone could help review my table relationships below for me and tell me where I am going wrong. I have ...
0
votes
0answers
22 views

Advice on table structure change

I am in the process of converting an Access application that stores and reports evaluations to being web-based using php and mysql. I have converted the structure and data over from Access and I have ...
3
votes
1answer
309 views

Removing “duplicates” within a time range

I have a table that contains number plate data with a date and time stamp, collected by a plate-reading CCTV camera at a site entrance. Vehicles stopping at the site entrance will create multiple ...
2
votes
1answer
197 views

Database design for a table with both bulk insert and single row insert

I have to design a table where records will be inserted in two ways. Bulk insert from a batch process from a delimited text file between 2 - 3 million rows in a short burst. Later the same records ...
1
vote
1answer
37 views

When using underscores, should they be reserved to junction tables? [closed]

Say you have the following tables company (contains companies) industry (contains industries) company_type (contains company types, e.g., Public, Private) company_status (contains company statuses, ...
4
votes
1answer
495 views

Database table design question

Firstly, database novice here. I'm trying to create a system for processing Sales Orders into Purchase Orders and then split the Purchase Order into Shipping Containers. The systems needs to be able ...
1
vote
1answer
155 views

Enforce a constraint problem

This business model is for a case management database. This is closely modeled on the idea of a file folder representing the phase and a sequential checklist representing the stages. A case consists ...