database-design

Which database would best suit the following needs?

I am trying to work out the best database(s) considering the following requirements: The bulk of the data is "document" style, with specific common fields that will be indexed. There needs to be joining across these indexed fields. However, the data in the indexes is heavily hierarchical, i.e., graph. A specific example is the hierarch...

MySQL data types: int versus enum

I have a number of columns that only need to store a few values (e.g. 0, 1, 2, 3). What datatype should I pick for such a case? I feel like I should pick something like ENUM('0', '1', '2'). Would int be better (despite it being less restrictive)? Should I consider something else (like tinyint)? EDIT: Actually, what general advice shoul...

When creating database for enterprise applications, is it any useful to keep create date

I have just started with professional programming and my manager tends to dictate that i keep create, modified and delete date in all database tables that we use. I want to know does it makes sense to keep these fields for enterprise application. The reason I am asking it that because all examples, tutorials i have ever read on net, book...

Tips for Database Design of Website with international Users

Hello Friends, i am developing a dating website, in which users can register from all over the World. The Dating section is divided into cities from again, all over the World. The Problem i see here is, i do not have a database that covers all cities around the Globe. I am confirming every user by hand so this gives me the opportunity...

Graphs and version control

I have a directed graph data structure, where I am trying to implement individual version control for each vertex. This creates some interesting scenarios, and I would much appreciate any ideas that you guys have. Specifically, I am looking to resolve the default behavior of the system when encountering the stated scenarios. See the fol...

is my data normalized?

I'm making a simple quiz database, where a question has an answer and one or more image files, and belong to a subtopic which in turn belongs to a topic. Also each group may belong to one of three levels. This is how I set up my database: QUESTION ------------------- question_id pk question varchar answer varchar subtopic_...

What would be a good order id scheme for a e-commerce solution or paid web service?

Considering the following: a) you want some confidentiality (as in not telling everybody how many orders you've received). b) you want a check digit (e.g., using the Verhoeff algorithm) at the end so you can easily tell misspells and help dealing with errors when scanning barcodes, if this is the case. c) you've to consider time so co...

Is there a program to draw entity-relationship graphs?

I have a homework that I wanna present neatly. ...

how to allow your code to store undetermined number of columns ?

Hi, I think my question might be unclear , but i would try to explain it by example . say that we had about 100 different car model , clearly all of the car would share common parts or specification but not all parts are shared between all of these 100 car brands what is the best practice of storing these specification in this case...