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

learn more… | top users | synonyms (1)

-5
votes
0answers
11 views

Anyone use devise-iOS [on hold]

I have started making an application. Basically going in just experimenting. I started out making a rails application where I used devise to sign up/in. I used Mongoid to store my database ...
0
votes
1answer
36 views

Best way to flatten an XML document

Say you have a document like this: <names> <first>Joe</first> <last>Smoe</last> <phonenumbers> <phonenumber ...
-2
votes
0answers
22 views

Which database to use for real time data update for trading and analysis? [on hold]

I am thinking about a website for trading and analytics. I am thinking which technologies can be used for this kind of website and so I have doubt with database. Which database is suitable for a ...
0
votes
1answer
37 views

Database searching for string across different tables

Scenario: application will search in database almost all columns across about 8 tables/views for defined string and return all rows containing that string (will return collection of objects or JSON). ...
0
votes
0answers
19 views

Recommendations for Big Data filter/formula language [on hold]

I'm working on a project which deals with terabytes of logging data which all must be preserved in it's original state. On top of this, to make it meaningful to the end user, it needs to have VERY ...
4
votes
1answer
42 views

What's the advantage of storing database transaction changes in the log as well as data pages?

I know the basics of why a database uses a transaction log - fulfilling ACID properties, ability to rollback/restore, etc. The basic algorithm that I see for a transaction is as follows: ...
-5
votes
0answers
18 views

I want split data's from a column into multiple rows and also with this I want split data's from other column into multiple new columns [closed]

I want split data's separated by comma(,) from a column into multiple rows and also with this I want split data's from other column into multiple new columns. Finally result will insert into new ...
1
vote
2answers
48 views

DB Design for non static front-end

I have a question about best practices to design a database which have to hold the following data: There is a page with a questionnaire which has default questions like Firstname, Lastname, Street... ...
-4
votes
1answer
31 views

Migrating MYSQL functions and stored procedures to SQL Server

The company i'm working for is selling HRIS management software. It was built using ASP and mysql. But one of our client's demand is for it to be based on MS SQL Server. our team is made up mostly of ...
0
votes
0answers
18 views

Best way to create “attributes” for Neo4j node?

I have this node labeled "Person" and these various items from what would be a class, in a conventional DB. For example: Teacher, Lumber, Magician, Artist and Painter. They should all fit in the same ...
3
votes
1answer
63 views

How to delete user data that is referenced by another user?

Lets say a user has a set of data. This data is stored in user_data table. This user_data table is referenced by other users in some way. In case the user wants to delete a row from the user_data ...
0
votes
1answer
22 views

User account model with two or three possible profile

My application will have at least two types of users: clients and companies, these are the types of profiles. Because each type of profile requires different additional information, it will be ...
4
votes
5answers
462 views

How to design a complex REST API considering DB performance?

I've been following some tutorials on how to design REST APIs, but I still have some big questions marks. All these tutorials show resources with relatively simple hierarchies, and I would like to ...
-1
votes
0answers
19 views

Store SQL queries in the database or in the server script? [duplicate]

I used to do queries from PHP by manually making a query string like "SELECT * FROM ... WHERE ... AND ...", but my office does it by making stored procedures in the database and just querying "CALL ...
2
votes
2answers
91 views

Database Design - lots of small tables or fewer, bigger tables?

So I'm designing a database for a project which is going to enable beauty businesses to create a profile, clients to create a profile and for the client's to be able to book appointments and for the ...
0
votes
0answers
33 views

Project that has no network involve, how can I update multiple databases?

I am working on a project that involves a very large area, for example this area is a big subdivision with 10 gates, because it is so big and we are aiming on producing a low-cost product and creating ...
5
votes
1answer
52 views

How can I better document these data relationships/transformations?

I'm working on a project that uses RxJS to perform data transformations on varying sources of data, and I'm in the process of writing some documentation for it. I want to find an effective way to ...
4
votes
4answers
173 views

Best practice for getting last record inserted in DB

Me and a couple of colleagues are having a discussion regarding the following case: In an OrderStatus table we're keeping track of all the statuses an order goes through in time, including ...
2
votes
2answers
70 views

Retrieving an incorrectly stored tree data structure

Way back in the hazy origins of our platform it was decided that we were going to need some hierarchical data structures stored in the RDBMS. The relationships between nodes were stored via a ...
5
votes
2answers
64 views

Junction table related to another junction table

I'm defining a DB structure, and I have a strong feeling I'm not doing it right. I have hotels that can be configured to offer some optional services (airport pickup, massage), that can in turn be ...
1
vote
0answers
22 views

Correlating Search Classifiers in a Database Scan for Sensitive Information

Problem Description I am working on an enterprise data discovery project that is designed to scan databases for sensitive information. The basic search unit is called a classifier and covers things ...
-1
votes
1answer
61 views

Is there a generally accepted definition of “Secondary Index” independent of DB product? [closed]

Is the definition for "Secondary Index" anything more specific than just "Any index that is not the primary index"? EDIT: Here is some research I have done: Search Google. I evaluated the first 20 ...
4
votes
1answer
70 views

How can we rollback a database synchronized over multiple systems?

On a mobile device, a set of operations has been saved in the local DB with a wrong date (because the system date was set in the future). Then the device regularly doing synchronisation with a server ...
41
votes
8answers
5k views

Isn't the use of NoSQL Databases impractical in a large number of use cases? [closed]

I've been learning about NoSQL Databases for a week now. I really understand the advantages of NoSQL Databases and the many use cases they are great for. But often people write their articles as if ...
0
votes
1answer
92 views

What is the significance of database host name while configuring database?

The name database host, how the name indicates "the server that hosts the database", should be the server ip, that hosts that database. I don't see any relation of it with the scripts that try to ...
2
votes
1answer
109 views

How to Manage Privileges in C# WPF applications

I'm writing my first "large" program in C# and WPF. It's a Database system (MySQL) that has three main items, Contracts, Companies and People. I have the main UI down for the Companies section of the ...
-1
votes
1answer
93 views

Efficient way to query thousands of records by ID from a Mongo document with hundreds of thousands of IDs - or is that infeasible? [closed]

I have a web application that registers users from Twitter. When someone logs in I want to fetch his list of friends and compare it with all the registered users ids in my database to see which of his ...
2
votes
1answer
76 views

Tracking online users with a stateless architecture

I own a stateless architecture, exchanging a JWT token between client and server at authentication time. I want to store in database (once per day) a timestamp related to the user access. Indeed, I ...
-1
votes
3answers
137 views

How likely are collisions of timestamp-based identifiers? [closed]

I overheard a discussion about using timestamps as unique identifiers when storing some data in a database. Person A pointed out that there's a risk of collisions. Person B replied that it's very ...
0
votes
2answers
126 views

DAO design for writing big XML file on database

I am currently working on JavaEE application (Spring, Hibernate). I have to put a big XML file (more than 1 gigabyte) on a relational database (Postgres). The application does not use batch ...
3
votes
2answers
87 views

Change database based on request origin

I am developing a web application which will be run by multiple companies. Each company will have its own instance of that web application and its own database. The web applications and databases ...
4
votes
2answers
85 views

How to represent a collection with capacity in a database?

Concerning normalization of a one to many relationship, I am not sure how to represent a collection with a specified capacity in a database. I can think of two ways to represent an entity A with a ...
-2
votes
2answers
88 views

Tables vs. Booleans: Which of the two are more secure for setting admin roles in an app? [closed]

I'm currently in the process of setting up roles where there are regular users, admins, and super admins, each of which have special permissions. I deferred to this post on how to do so. It ...
1
vote
0answers
32 views

Compiling data from multiple API sources, multiple languages, into a single database (MySQL or Mongo)

I'm thinking about a database schema, and would really appreciate if some of you could look at where I'm up to and offer some advice.. The mission - We have to write a program that will fetch data ...
0
votes
1answer
75 views

Is it advisable to create a single API to access the database? [closed]

Got an organization that its core work is acquiring various sources of data, validating it and integrating it to existing mostly financial data sets and then availing that data to many different types ...
4
votes
1answer
88 views

Can't I use an enum at application level if I have a NxN relationship?

After reading the answers to this question, and this and this related questions, I'm now confused about how/if to work with an enum having an NxN relationship. Let's say I have an entity Hotel, an my ...
30
votes
7answers
4k views

Why would you store an enum in DB?

I've seen a number of questions, like this, asking for advice on how to store enums in DB. But I wonder why would you do that. So let's say that I have an entity Person with a gender field, and a ...
5
votes
2answers
114 views

How to store ordered information in a Relational Database

I am trying to understand how to properly store ordered information in a relational database. An example: Say I have a Playlist, consisting of Songs. Inside my Relational Database, I have a table of ...
1
vote
1answer
42 views

Executing queries against multiple separate database instances

Premise I have a number of database servers (different DBMS instances, installations in different physical locations), each of them contains data and uses the same schema. Most of the data is ...
3
votes
3answers
59 views

Handling Value Unit data

We have some data that is strongly bound to each other and we are using it for calculations. Its a value with a unit type and an optional relation. E.g. 1500 meter above sea level. The unit type ...
4
votes
2answers
143 views

What is the recommended strategy to deal with a frequently changing database model during development

A lot of projects have a to be determined database model during early development. This could mean that a lot of SQL will have to be rewritten frequently. What is the recommended strategy to deal with ...
5
votes
3answers
138 views

Is it a good practice to have a pre-filled embedded database for development?

I'm currently working on a project which only uses its database for data storage. This means there are no triggers or stored procedure in it, just tables and data to put into it. In this scenario I'm ...
1
vote
3answers
172 views

Enforce uniqueness of personal contact records in a system or not? [closed]

I have a contact table which stores all the contact information of a person such as name, address, phone number. The system would be more user friendly if it can prevent users from accidentally ...
0
votes
0answers
30 views

Where should user input be validated? [duplicate]

I am working on a webbased user interface using AngularJS. As a database I am using MongoDB which can be accessed through an Python-eve-API. The API is able to validate the passed data as stated in ...
3
votes
2answers
78 views

How do I model a sortable resource in sql database? [closed]

I encounter this issue when I create REST API. I cannot tell the exact scenario, but let's say it is for a website that has category and product resources. Each category has many products and both ...
12
votes
5answers
766 views

How to avoid violating the SRP in a class to manage caching?

Note: The code sample is written in c#, but that shouldn't matter. I've put c# as a tag because I can't find a more appropiate one. This is about the code structure. I'm reading Clean Code and trying ...
32
votes
6answers
4k views

What is a good security practice for storing a critical database on developer's laptops?

We have a few givens: Developers need a replica of the production database on their machines. Developers have the password to said database in the App.config files. We don't want the data in ...
2
votes
0answers
72 views

Upload, convert, and store multiple different product data feeds into a database

I'm not sure if this right location for this question, but here it is. I currently have about 30 different CSV or TXT product data feeds. I am trying to build a tool to 1) upload each feed 2) ...
4
votes
2answers
46 views

AutoIncrement Integer Column,Guid or PGuid, which to choose?

Guid has been a Global Unique Identification. Why does "PGuid" (Global Unique Identification) appear? 1) Is Guid NOT PERMENT for unique? (I sometimes wonder whether Guid is REALLY PERMENT generator ...
0
votes
1answer
70 views

Django Migrations: Binds data to code?

If you have custom code for models (custom validators and custom fields are examples), Django Migrations will import them directly into the migration files. An example: file web/models.py def ...