The data-modeling tag has no usage guidance.
6
votes
1answer
214 views
How should I design an ordered list resource in a restful service?
I've run into this same problem over and over again and I haven't found a solution that I really felt was optimal.
Say in an app, you have an ordered list and you let the user change that order by ...
1
vote
1answer
78 views
How can I model IS-A relationship on a ledger, when having different classes of products?
This is a question on how to model database entities and relationships when it comes to storing persistent data and dealing with differently-handled types of products.
Use Case
Company sells various ...
0
votes
1answer
46 views
DDD - modeling of similar categories with different behavior
I have a question related to modeling similar Class of objects in a DB:
Suppose in the database i have a list of clients which can be in different categories - eg. Client --> can be in Category1 ... ...
0
votes
0answers
24 views
How to model universal search response with heterogeneous results
I need to model something similar(but little different) to Google Universal Search where the response object is heterogeneous that contains Video, Images, Web Pages, Documents, etc coming from ...
4
votes
2answers
76 views
Graph database keeping historical relationships
I'm starting the modeling of the following problem:
I have many clients (millions) that interact in a network forming a graph. At the highest granularity of my business problem, each realationship ...
2
votes
4answers
114 views
Data Model - How to better model this circular reference
I'm designing the data model for a project where users can create documents, save revisions of that document that can be reverted to, and publish documents. The basic data model I have right now is ...
3
votes
1answer
206 views
RESTful API/Data Modeling - How to model an subordinate resource that will only ever have one element
I'm creating an API and data model for a multi-user document-creation application and I'm having trouble with a particular part of the data model/API design. Below is my current line of thinking:
...
1
vote
2answers
112 views
How to model the database tables for calculating on peak and off peak usage data
I am using MS Sql Server and my system contains power usage data in one table as timestamp and values for KW(two columns). This data is collected at 1 hour interval.
At the end of the month I need to ...
1
vote
1answer
80 views
How many vertices/nodes are too many in a graph and stop being beneficial?
Background
I'm working on a project that requires me to keep track of transactions as well as the flow of items in a game.
In order to do that, I'm storing those transaction in a graph db (Orient-DB)....
4
votes
3answers
72 views
Using Multiple 'Sub-types' vs a larger single type?
I have a user model in an application that I'm working on, which currently uses sub-types to encapsulate properties depending on what type of user you are - I just can't help but think that this is ...
0
votes
3answers
255 views
Designing Pricing table (RDBMS agnostic)
I'm designing a pricelist table for my database.
It will include Customer, Model, Start_date, End_date, Price, Currency, RRP
When I update a new pricelist which is sent every now and then (maybe ...
-1
votes
1answer
58 views
Software architecture entity connections [closed]
For learning purpose I want to create an app.
So I thought I will do something real easy to learn a lot about object oriented programming and modelling. After some thinking I had the idea to do a ...
2
votes
4answers
309 views
What is the best data model to represent mathematical range (in database, xml, json…)?
For example,
greater or equal to 50 and smaller than 100 (>=50 && < 100)
smaller than 10 or greater than 40 (<10 || >40)
I have been thinking about how to represent ...
1
vote
0answers
35 views
Adding fields a good use case for EAV? [duplicate]
Is being able to add fields quickly to a system a good use case for EAV? What would be the frequency or number that would justify using an EAV model?
5
votes
2answers
1k views
Database Design for Inventory
I am starting to design a typical product based MySQL database but I keep running in circles on how to design the tables.
I have many types of products
Jeans
Tshirts
Dresses
Which have many of ...
1
vote
1answer
437 views
Likes / Stars / Following - same or separate data structures? [duplicate]
I am building a social network, which will have standard features of 'likes' (upvotes) for posts, 'following' between users and 'stars' for favorite posts. These might reasonably expand in the future ...
1
vote
2answers
180 views
How can I create a model to efficiently answer the question of - where to place my db-interaction code I am about to write?
I am seeking the right model for storing and retrieving data, when working with any specific class, while keeping in mind the bigger picture.
Details:
I have some SQL code in (one) of my classes and ...
2
votes
1answer
167 views
What happens to database design process when ORM tools are used?
I have learned about database design, including normalization during my undergraduate course. When we have to model a database for a system, we can start with an ER model and then convert it to the ...
2
votes
1answer
51 views
Converting a one-to-many xml design to a many-to-many
I have an xml file format that looks something like this:
<topLevelTag>
<category name="foo">
<item attrib="value">ItemName</item>
<item attrib="value2">...
4
votes
1answer
297 views
Should I avoid data duplication?
I'm trying to design a relatively simple ERP system. However, there are some requirements that complicate things a little bit:
It must be possible to add all sorts of contacts to the people table, ...
2
votes
2answers
137 views
Should ids be mapped to the implementation type
This is a question of model design, and hopefully some architecture nerds have strong opinions on this. I've been developing one that I will post in an answer.
Typically, in every codebase I've ever ...
1
vote
1answer
375 views
Implementing a NoSQL and RDBMS compatible DAO
What would be the correct way to design a DAO which implementation is first going to be targeting a MS SQL database with a STAR model, but yet, business requirements specify the application must be ...
5
votes
3answers
131 views
Is an enterprise-wide data model truly feasible?
I've consulted for a number of Fortune 500 and 100 companies all of whom have made some kind of effort at creating a "Master" data model even to the point that they'd attempt to have all applications ...
3
votes
4answers
133 views
Two user inputs that alter each other
I have a user interface with two numeric input boxes, send amount and receive amount. The values are in different currencies and are related by an exchange rate. That is, receive amount should always ...
5
votes
2answers
265 views
In an MVC, should models use libraries, or should libraries use models?
When I build a RESTful API, I use an MVC pattern. And in order to make controllers skinny and code reusable outside of the API (e.g. in Cron tasks), I put much of my code into services (commonly known ...
3
votes
0answers
240 views
Lightweight data modeling vs traditional classes [closed]
I've heard a lot of talk about using lightweight data modeling as of late. Especially in relation to the Clojure programming language. What is it and how it differs from traditional classes regarding ...
2
votes
1answer
261 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 ...
3
votes
0answers
203 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
...
10
votes
6answers
1k views
How to model more than one 'last name'?
In Spanish-speaking countries we use more than one last name, like:
First name ↘ ↙ Last name
&...
4
votes
1answer
1k views
Data Model for selling groups of products as one product
Say I have an e-commerce with a data model like the following, which allows a Sale to describe how a single Product is sold. This division allows a product to be sold multiple times in different ways (...
0
votes
1answer
259 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 ...
4
votes
4answers
550 views
How would you model an objects representing different phases of an entity life cycle?
I believe the scenario is common mostly in business workflows - for example: loan management
the process starts with a loan application, then there's the loan offer, the 'live' loan, and maybe also ...
3
votes
1answer
167 views
Algorithm/Strategy or Data structure to capture priorities sub priorities in an app
I am working on a CMS that is starting to evolve a bit.
We started off with content that had the following priorities ( columnn in the db on the content table): HIGH MED LOW. Data was fetched by ...
3
votes
2answers
221 views
What's a good format for documenting hundreds of data feeds?
Several governments are starting to publish open data: datasets generated by the goverment, made freely available for citizens to use for value-added app development, analysis, and feedback. For ...
1
vote
5answers
3k views
Is it Considered Good SQL practice to use GUID to link multiple tables to same Id field?
I want to link several tables to a many-to-many(m2m) table.
One table would be called location and this table would always be on one side of the m2m table.
But I will have a list of several tables ...
0
votes
3answers
1k views
How to show or direct a business analyst to do data modelling? [closed]
Our business analysts pushed hard to collect data through a spreadsheet. I am the programmer responsible for importing that data. Usually when they push hard for something like this, I never know ...