This tag is for general database questions; if you question is specific to SQL use that tag instead.

learn more… | top users | synonyms (1)

2
votes
0answers
81 views

Logging Database Changes

What is the proper way of storing a changelog, similar to git, for data in a database. Currently, I have it set up so that every line in a table is given a unique string id that is used to ...
1
vote
0answers
60 views

Saving tabular, spreadsheet-like data in a relational database?

I'm hoping this question isn't too broad or too prone to opinionated answers, since I could really use some pointers. I'm trying to come up with a way to persist tabular, spreadsheet-like1, data in a ...
1
vote
3answers
116 views

How can one think of a relational schema in terms of storing it in a NoSQL database?

Recently I've been wanting to experiment with NoSQL databases, especially document store ones. After reading, I still don't understand how one might model information that is contained in a relational ...
1
vote
1answer
158 views

What is the correct reusable architecture using Entity Framework for common database tables and services?

Context I have a line of business application "MyApp" in C# using EF. Layers are separated as MyResusableLib.DataAccess // Class Lib: EF based utils, extension methods, MyApp.DataAccess // Class ...
58
votes
7answers
6k views

Why does the relational model for a database matter?

I am approaching a project where I'll be having to implement a database with my boss; we're a very small start up so the work environment is deeply personal. He had given me one of the company ...
2
votes
1answer
43 views

Efficient saving of long strings with recurring substrings

following problem: I need to save a lot of xml strings of variable length and structure. As it is with xml, a lot of substrings are the same (some elements, attribute and value combination). Often the ...
0
votes
2answers
89 views

JSON or XML or other - most time efficient for largely “read” of structured data

Considering that using a relational DB or other hierarchical or such databases is not an option, looking for the alternative approach using a simple (but very fast, efficient, distributed KV-store). ...
1
vote
1answer
59 views

How to associate similar data with different tables in a database?

My application has users and ads. A user has a unique email. An ad belongs to a user (so, the ads table has a user_id FK, that is simple). Every ad can also have multiple emails and phone numbers ...
0
votes
0answers
32 views

Develop an API within ESB to access a database

I am working with a service provider where I need to get data from their service. The service provider wants to give me access to their database to get the data I need. My question is should I ...
0
votes
0answers
14 views

Regional test-of-concept environment, whose database must be merged back to the main server afterwards

My client wishes to launch a specific version of the Rails platform I am developing that will be restricted to a particular group of users (some sort of test-of-concept). I will have another server ...
2
votes
0answers
71 views

Maximising data processing speed: in-memory or write to db first?

Currently working on a system which allows users to upload data files, which we then "clean" (i.e. process in various ways). Speed of processing and return to the user is an important consideration, ...
2
votes
1answer
73 views

Implement pagination which memorizes where we left off?

Let's pick a relation database table (say an audit table) with high write rate. We can display 100 records at a time. But as a user don't want to see some the records on page 1 on page 2 when a couple ...
5
votes
6answers
182 views

Should I add a “boolean meaning” to another column?

Is it a good/bad practice to add a "boolean meaning" to other fields? For instance, let's say I'm modeling events, that might be recurring or not. I can have: A boolean column that holds if the ...
-1
votes
1answer
66 views

Any Non-Singleton PHP PDO Db Connection Examples? [closed]

Are there any good examples of non-Singleton PHP PDO Dbfactory or connection classes people can point me in the direction, or perhaps even briefly illustrate. I am interested in learning both support ...
-1
votes
1answer
57 views

How costly is DB data transfer as compared to data storage?

I've seen a number of answers (1, 2, 3) where they state that storage is cheap. So when designing a DB structure, it shouldn't be a main concern, or at least it doesn't rank very high in the list of ...
0
votes
1answer
69 views

Datagrids vs Databases - what are the differences?

There are some datagrids I had quick look into: Angular UI Grid ag-Grid, one more link Kendo UI Grid Also, previously I had a very small experience with MySQL. What are the differences between (a)...
4
votes
3answers
58 views

Getting the same data in multiple ways

Say I want to get the same data from an SQL database, but want to have multiple ways of getting that data. For example, say I want to be able to search a database for users based on username, real ...
0
votes
3answers
73 views

Should an audit user column be nullable?

Consider following table structure, for the backend of a website: [Article] ArticleId Text TotalViews AuditModifiedOn AuditModifiedByUserId [User] UserId An anonymous/not authenticated user visits ...
1
vote
1answer
172 views

Getting data from a database with the MVC model

I am creating an application which will have a very large database to draw it's information from (a student registration system to be exact). The database is created with Microsoft SQL Server if that ...
1
vote
3answers
105 views

Are crow feet notation and uml notation same?

Does crow feet lies under the sub category of the UML notation or it is a whole other approaches. As far i have seen only difference between two of them is that crow feet uses crow symbol |------<-...
2
votes
1answer
59 views

How to optimize a bloated entity that causes a huge query

I have an application that exposes a series of Web services. One of my entities has a bunch of one-to-many and many-to-many relations to other entities. My transactionality level is at DAO, and I'd ...
0
votes
1answer
43 views

Keeping track of data deleted upstream

I'm building an application that queries several APIs and duplicates some of the data in a downstream, centralized database to make it easier to perform some processing on it. My application will only ...
1
vote
1answer
159 views

How to store data from firebase to analyze at some later date [closed]

I am currently using Firebase with my iOS app. I use it to authenticate users and then allow user interactivity during the life of the app session. I would like to be able to save a snapshot of my ...
1
vote
3answers
47 views

Archiving data by semester

The problem is similar to this question, but not a duplicate. What I'm looking for is a better solution than my current one. I'm building a web application for a department in my university, and due ...
-1
votes
1answer
35 views

Defining a DB schema and having existing schema conform to it? [closed]

I see a lot of DB migration tools that have up/down functions that deploy/revert DB schema changes. I have never seen a migration tool where you simply define the schema and it modifies your current ...
0
votes
1answer
73 views

How to do an “Automatic DB monitor” and notify the client

Until now I didn't find anything good about monitoring a DB's specific table (or related tables) specific values changed. I want to know: Since most of DB's don't support monitoring changes for ...
2
votes
1answer
228 views

How is one or more aggregate function implemented in most SQL engines?

In the book Database Fundamentals, Silberschatz. It is explained that aggregate functions can be calculated on the march. This make sense. What it means is that for calculating the maximun, average ...
0
votes
1answer
42 views

Licensing and copyright terms for data from Wikipedia

I have an idea for a client-server software project which involves using information from Wikipedia, but I am not sure about what the conditions for using it in regards of licensing and copyrights ...
43
votes
6answers
3k views

Business logic: Database vs code [duplicate]

I'm a student of systems engineering, and all my teachers and friends (that actually work in the area) say that it is better to have as much logic as possible implemented in the database (queries, ...
-3
votes
1answer
213 views

C# Share Datatable in Multi-threading

I am beginner in Multi-threading in C# & confuse in current task. My task is to read datatable and display datatable in C# console application using multi threading. I have three threads and one ...
1
vote
0answers
26 views

Offsetting high usage in a multi-tenant database environment?

I'm writing a research essay over distributed cloud-based systems, and one of the topics that I'm trying to touch on is potential solutions to high database utilization in a single-database multi-...
64
votes
7answers
6k views

How does a surname of Null cause problems in many databases?

I read an article on BBC. One of the examples they said was that people with surname 'Null' are having problems with entering their details in some websites. No explanation is given about the error ...
3
votes
3answers
180 views

When dealing with tens of billions of rows in a web app table, would a NoSQL database be noticeably faster than a relational one? [closed]

I'm currently designing a conceptual web app, where users can submit posts, comments, and "like"/"dislike" both of those. However, I am not sure of how to store the (dis)likes, because of how many ...
0
votes
0answers
21 views

Is having a singleton collection in Mongo (i.e. equivalent of an SQL table with one row) an anti-pattern?

I've been looking for ways to implement this, and haven't found it anywhere, so wonder if I'm doing something silly. Essentially I have a set of information which is relevant to the entire database/...
1
vote
1answer
45 views

Should arbitrary numbers be stored as strings in a database?

I'm using Google as a login system for my latest project. So, my users table has a column named googleid, which stores Google's unique user id, which is a number, with a few dozen digits. For example, ...
0
votes
0answers
29 views

Should I use weak entity instead of regular to describe my kind of components?

First time trying to make a E/R model of my database. Trying to understand weak entities and regular entities. Should I make the CPU, RAM, Mainboard, etc. entities weak instead of regular?
4
votes
1answer
85 views

In a master-slave replication mechanism, how do you avoid / cope with the fact that the master is a single point of failure? Is there a solution?

So master-slave replication is great, but it leaves the master as a single-point of failure. What is the strategy to solve this problem, if there is one? I'm looking for the computer science theory ...
6
votes
3answers
121 views

Handling retroactively adjusted data that is reported hierarchically

Several of our customers have come to us with an interesting problem that involves adjusting data that occurred in the past which is rolled up and reported based on an org hierarchy. For example: If ...
0
votes
5answers
389 views

How is it possible to log a user into a system with billions of similar data without delay?

Taking for instance Google mail and Facebook, they both have a huge database of users. It would be easy to search through a database of 100 similar logins and find a match in a second, but not in the ...
5
votes
3answers
61 views

What are the theory behind implementing two mirrored HashMaps that can accept write operations? Do I need a broker to mediate conflicting writes?

So imagine two HashMaps that need to be mirrored across two different machines, A and B. Whenever I make a modification to machine A, machine B sees it and vice-versa. Problem is: These two hash maps ...
19
votes
4answers
628 views

Using flat files vs database/API as a transport between a frontend and backend

I've got an application which has generated a rather heated discussion between a couple of the developers. Basically, it's split into a web layer and a backend layer. The web layer collects ...
3
votes
1answer
93 views

Managing a development database in a group project

I'm working for a small webdevelopment company and we want to set up development environments. We'll be using the Laravel framework in combination with Homestead. Now, Homestead has its own database ...
0
votes
1answer
74 views

Is it a bad practice to use external files for storing SQL templates?

I am working on a report system which aggregate a lot of data from multiple sources (databases and internal APIs). Among other things I communicated with another departaments and told them I need some ...
1
vote
1answer
194 views

How should I implement a full text search into my meteor web app?

I am making a web application using the javascript framework Meteor, which runs with mongodb. In the web app I have a db set up that holds individual video games in the documents. An example of this ...
2
votes
0answers
164 views

Speed: Named Shared Memory vs Memory Mapped File vs Normal Memory

Let's say I have a server, where clients who connect are constantly updating their inventory. I could simply save the changes in to the database after an item has been updated, or I could update the ...
5
votes
3answers
205 views

Use of booleans in a database

I'm using Visual Studio 2013, .Net 4.5 and SQL Management Studio 2012. I have a table that tracks offices in my database. On the application side there are a some display rules regarding the layout ...
1
vote
1answer
89 views

Manual reload of Java classes static block

I have a static block which fetches data from database. This data is then being used by instance method. Since static block will be loaded once I fear that the data won't change in its lifetime. How ...
3
votes
1answer
119 views

Is it good practice to access database in mapping between object

Situation I receive message from a 3rd party, and these messages are use to create or update database information. Message and data to be updated can be de-serialize in object form, but are not ...
4
votes
6answers
235 views

Sharing database interface functionality among multiple applications

I am currently refactoring some old code and I am facing some architectural problems. Currently 3 applications are working with the same Database (as follows): Content inserted by user Content ...
1
vote
2answers
309 views

Multiple instance of the same class?

I have a class named "Category" to handle all the operations and data about my categories. Now, my class is created however I need to find a way to build an object for each of the categories in my ...