Questions tagged [data-modeling]

Data modeling questions refer to the techniques used to gather and analyze data requirements needed to support data operations in programs and systems.

Data modeling consist of gathering requirements and knowledge about the data needed to solve a given problem, and elaborating abstract data structures for the purpose of designing and implementing standardised data formats, databases and data processing systems.

Data-modeling is a specialized kind of modeling solely focused on passive data structures, and independent of the description of the processing of that data.

3039 questions
64
votes
2 answers

Data modeling in Datomic

I've been looking into Datomic, and it looks really interesting. But while there seems to be very good information on how Datomic works technically, I have not seen much on how one should think about data modeling. What are some best practices for…
Tobias Furuholm
  • 4,727
  • 4
  • 30
  • 39
63
votes
1 answer

Why should I avoid loops when designing relationships for a database?

Someone told me that it was bad design to have loops in the datamodel. I have heard this before a couple of times but didn't pay much attention. For example you have entities User, Project, Activity. A project is owned by a User, so we have a…
59
votes
11 answers

Finding the best trade-off point on a curve

Say I had some data, for which I want to fit a parametrized model over it. My goal is to find the best value for this model parameter. I'm doing model selection using a AIC/BIC/MDL type of criterion which rewards models with low error but also…
Amro
  • 123,847
  • 25
  • 243
  • 454
58
votes
9 answers

Is it good database design to have admin users in the same table as front-end users?

I have users who can login on a front-end page, and admins who can login on an admin page. Should both users and admins be "Users" with different roles, or should they be split in different tables?
Steven
  • 18,761
  • 70
  • 194
  • 296
54
votes
5 answers

Alternatives to Entity-Attribute-Value (EAV)?

Our database is designed based on EAV (Entity-Attribute-Value) model. Those who have worked with EAV models know all the crap that comes with for the purpose of flexibility. I asked my client about the reasons why using EAV model (flexibility), and…
50
votes
2 answers

What is an "order line"?

I listen a number of podcasts. Often I hear the expression "Order line" in the context of database or business object modelling. It seems to be the canonical example of something. I just don't know what. So what is an "order line"? What concept does…
steenhulthin
  • 4,553
  • 5
  • 33
  • 52
49
votes
2 answers

Modeling Tool for NOSQL Databases

I know that most of the time NOSQL databses are schema-less or at least have a flexible database schema. However, the basic schema needs to be modeled beforehand and may evolve later. So,in this case, is there a modeling tool/language for NOSQL…
SoumaZ
  • 629
  • 1
  • 7
  • 14
47
votes
12 answers

Why use an auto-incrementing primary key when other unique fields exist?

I'm taking a course called "database systems" and for our class project I have to design a website. Here's an example of a table I created: CREATE TABLE users ( uid INT NOT NULL AUTO_INCREMENT, username VARCHAR(60), passhash VARCHAR(255), …
cnandreu
  • 5,113
  • 3
  • 25
  • 50
47
votes
4 answers

Forward Chaining vs Backward Chaining

What is one good for that the other's not in practice? I understand the theory of what they do, but what are their limitations and capabilities in practical use? I'm considering Drools vs a java prolog for a new AI project, but open to other…
gtrak
  • 5,598
  • 4
  • 32
  • 41
46
votes
6 answers

What is the best way to represent "Recurring Events" in database?

I am trying to develop a scheduler- and calendar-dependent event application in C#, for which a crucial requirement is to represent recurring events in the database. What is the best way to represent recurring events in a database? More…
Varma
  • 771
  • 1
  • 9
  • 19
45
votes
5 answers

How to do Inheritance Modeling in Relational Databases?

My question is regarding Inheritance modeling in Relational Database Systems. I have canonical data model and in that I have some fields related to pricing of product inheriting certain attributes from product table and I want to model this…
Rachel
  • 100,387
  • 116
  • 269
  • 365
44
votes
4 answers

What mysql database tables and relationships would support a Q&A survey with conditional questions?

I'm working on a fairly simple survey system right now. The database schema is going to be simple: a Survey table, in a one-to-many relation with Question table, which is in a one-to-many relation with the Answer table and with the PossibleAnswers…
kender
  • 85,663
  • 26
  • 103
  • 145
43
votes
8 answers

Do you use Styrofoam balls to model your systems?

[Objective-C] Do you still use Styrofoam balls to model your systems, where each ball represents a class? Tom Love: We do, actually. We've also done a 3D animation version of it, which we found to be nowhere near as useful as the Styrofoam…
Nick Dandoulakis
  • 42,588
  • 16
  • 104
  • 136
42
votes
4 answers

What's the difference between Data Modelling and Domain Modelling?

By the way - with reference to data modelling I'm referring to logical or conceptual data models - not physical ones. The question came up during a discussion at work; naturally I leapt to Wikipedia to get some basic definitions in place - hoping…
Adrian K
  • 9,880
  • 3
  • 33
  • 59
42
votes
6 answers

Facebook like notifications tracking (DB Design)

I am just trying to figure out how Facebook's database is structured for tracking notifications. I won't go much into complexity like Facebook is. If we imagine a simple table structure for notificaitons: notifications (id, userid, update,…
Atif
  • 10,623
  • 20
  • 63
  • 96