The tag has no usage guidance.

learn more… | top users | synonyms

1
vote
3answers
60 views

Relational tables with same content, custom solution

So let`s say that I am building an app where I can add comments for FOO. Normally I would have something like this: Table foo and table foo_comments, where foo_comments contains id, foo_id and other ...
16
votes
5answers
16k views

What's better for large changes to a table: DELETE and INSERT every time or UPDATE existing?

I am making a project where I need to change around 36K records in one table daily. I'm wondering what will perform better: delete rows and insert new ones, or update already existing rows For me ...
0
votes
0answers
29 views

Mongodb database design

I'm planning to implement this schema in Mongodb, I have been doing some readings about schema design, and the notion was whenever you structure your data like a relational database you must be doing ...
1
vote
1answer
29 views

Keep files in mongo as part of the data

I want to create a news app that works in the following way: The site will contain articles, and each article with have multiple versions. Each version is a docx file and the article itself does not ...
2
votes
0answers
32 views

Design university schedule system

I'm not sure if this is the right place to ask for tips and improvements in a database design but I don't know about another one. I want to design a simple University system. Below I'll have included ...
-1
votes
1answer
151 views

Database design for timetable in mysql

I have to make a web application in java. The web application is like a online appointment book. Everyday of the week has 1 column with times from 9.00am to 10.00pm (only full hours). I already ...
2
votes
0answers
40 views

insert/update from web server or database

I have a data-model on the front-end that I want to insert/update in the database which of the following approaches (or neither!) is considered best practice: # in webserver some_model = {json} ...
0
votes
0answers
17 views

Reusing domain specific queries

I'm trying to cut down on duplicate code on a project(queries) but due to constraints, I can't seem to grasp how. The constraints : I work on a slave DB from a vendor (I have only select ...
6
votes
2answers
220 views

Efficient Database schema for multi-lingual content?

Assume I have a table for blog posts, posts, and schema as id author title content and each post can belonged to some categories id name descrtiption So a blog post can belong to multiple ...
0
votes
0answers
37 views

Is double one to many a bad design? It looks duplicate when joining both one-to-many tables

Suppose I have user table, book table, DVD table. User can borrow n book, n DVD at the same time, a book or a DVD can be borrowed by a user. (I understand it is many-to-many situation in real life, ...
3
votes
2answers
45 views

How to prevent duplicates while storing result from different application

For my case multiple application uses data from db based on date, this data is date specific so if for a date data exist application should just read it otherwise it should fetch information from ...
0
votes
1answer
160 views

How would you design a table for approval system between User and Sports Club

I am currently learning database modelling and struggling to model the following requirement. I have a user and sports_club table. User can only join a sports_club if three existing users of the club ...
21
votes
4answers
23k views

Are individual queries faster than joins?

Conceptual question: Are individual queries faster than joins, or: Should I try to squeeze every info I want on the client side into one SELECT statement or just use as many as seems convenient? TL;...
1
vote
0answers
28 views

Storing resource information efficiently

I'm looking for any advice on how to efficiently store some resourcing data for our app. For each project in our system we need to store the resources required and this comes in the following form: ...
0
votes
0answers
22 views

Is it secure to disclose the key value of tables

I am currently working on a web application. And the application would link user to data with primary key of some table so user can find the key value (int). Is the application still safe? Or should ...
1
vote
1answer
161 views

What is the best way to represent an Team and player relationship in ERD

I am working on designing an ER diagram for a football system, i stopped in the relationship between the player and team, as we know the player plays for only one team and team have many players, so ...
2
votes
1answer
225 views

How would I model the Twitter lists functionality?

I'm working on an application which would mimic the Twitter Lists functionality in which someone can follow someone else. Each user can also create objects which can be followed by users. The Twitter ...
1
vote
1answer
42 views

design database with 2 simillar tables

I have a database which has product_sell and product_buy tables, these two tables are different in a few fields and each one has own comment table product_sell >---< product_sell_cmt ...
1
vote
1answer
46 views

Is it possible to execute queries in random order?

I have a list of INSERTs, UPDATEs and DELETEs queries. My problem is that I always receive them in the wrong order (random), and I cannot know their original order. Are there techniques to group/...
1
vote
1answer
63 views

Should my application utilize database credentials for user login?

I'm working on an application that has an ASP front end and a SQL Server database. The way credential management is currently performed is there is a custom built User Table in the database that ...
0
votes
2answers
119 views

Heavy load causing MySQL Slave threads to remain “locked” or “Sending data” indefinitely

We have been rapidly adding MySQL servers as slaves to our master database server to help alleviate a massive increase in search (read-only) traffic to our web service. This past week, I was tasked ...
0
votes
0answers
103 views

A transition table, is it a good idea?

I'm writing an application that stores a project's C++ API representation. For example, I have tables like Class, Function, FunctionParameter, DerivedClass, BaseClass, and so on. Every once in a ...
0
votes
1answer
109 views

when to put a business rule in the business application layer or into a database constraint

I need you wisdom, I am debating with another person when is it recommended to put the code of a business rule into a database constraints or inside of the application business layer? There is a ...
0
votes
1answer
587 views

Database structure for users, events and event lists

I am creating a web service for managing events. The service will have users, who are listed in one database, called Users. It will also have events, which are listed in another database, called ...
0
votes
1answer
79 views

Comma List vs Multiple Records

I am currently building out an application that will contain many users, two roles and two groups. Logically we want users to be able to be administrators of other users within the two groups. User ...
0
votes
1answer
185 views

Division Email Template DB Design [closed]

First question for me on the DBA SA site! This is for an Java email notification app using MySQL for backend. I have a small number of groups in our organization, [Marketing, Commerce, ...
0
votes
0answers
41 views

Tables with same schema in DB for different sources. Bad pattern?

The main purpose of the system being developed is to collect data from different sources, process and standardize it, and then add it to the DB. After information from all sources is collected it ...
0
votes
0answers
50 views

Database & Structure for SaaS reporting software

I'm building a SaaS application to allow users to upload data and perform reporting and analytics on it. The reporting and analytics would be quite simple like grouping and aggregating. This has ...
2
votes
2answers
216 views

Overhead of decomposing complex query into multiple simple queries?

What kind of overhead should I expect when replacing a single complex query with multiple simple queries? My goal is to improve the readability and portability of all SQL code so I will be favoring ...
0
votes
0answers
21 views

How to model mappings at various levels

I'm trying to design the database model for my application and I'm finding it difficult to design the mappings for user access to various entities stored in the database. If access was only ...
0
votes
1answer
14k views

Inserting data into multiple tables

For my system, students are required to create a user account by completing a registration form (personal, contact and course details; also username and password). I need to collect registration data ...
4
votes
2answers
256 views

Database instance and database

I did some research and finally came to this conclusion: Database instance = processes + memory Database = (physical) log files + control files + data files. Is this understanding correct? ...
0
votes
1answer
86 views

Is array serialization always bad idea?

I'm making form-generating app in php. I have Widget table with type_id (html input) field, and I would like to add options field, like width/height, step, range, etc. Different widgets do have ...
0
votes
1answer
676 views

Airport Database Design guidance required

I am trying to make a generic database for airport management and DBMS would be oracle 11g xe. Since, i am amateur and still learning so i have tried to kept the problem statement simple with limited ...
1
vote
0answers
352 views

user rights validation inside stored procedure?

You have an application with a Users table, and the Users table has various columns to indicate what rights a User has within the application. Ignoring for the purposes of this question what should ...
0
votes
0answers
116 views

Efficient way to fetch/update X records in a loop

What I need is a simple process that handles requests. I have setup a simple table as follows: CREATE TABLE Requests ( id INT NOT NULL AUTO_INCREMENT PRIMARY KEY, request_param VARCHAR(250) ...
0
votes
1answer
225 views

Help With MySQL Computed Columns/Auto Updating Field Based On Average

I am currently building a social network type application on-top of MySQL and have run into a problem I can't wrap my head around. In my web application each user has a field called "weight" and this ...
0
votes
1answer
646 views

Digital content eCommerce schema advice? [closed]

I don't have much experience designing databases, I'm looking for some advice on my design from more seasoned designers/developers. I'm developing a digital content eCommerce store which will be ...
2
votes
1answer
60 views

Denormalize Design Modification

Our DBA is on medical leave, I am just a developer trying to do my part. Initially, the bean counters were going to use quickbooks. However, after seeing how much time they could save with custom ...
0
votes
2answers
130 views

Trigger calls and application code

When a trigger is set on a table does the application code wait for the original statement and the trigger to execute before resuming or just the original statement? Consider application code to be ...
0
votes
3answers
219 views

Design concerns for using 3x bit or one char(1) or one integer in table for holding status of item

I need to extend my existing table with status column. I am in doubt how to do that in most appropriate way regarding of future use of that status and performances of existing table. My table is ...
0
votes
1answer
227 views

Whether or not to create separate tables

I am working on a project, where I need to store the information related to A and B, the A and B both have identical columns.There might be thousands of As and Bs. Should I use "type" column to ...
1
vote
1answer
122 views

what is the best practice when making changes to the the application and database?

I need to make changes to an application which utilizes a database that is replicated across locations. I was wondering what the best practice is when working with databases and making changes to the ...
4
votes
4answers
1k views

In Memory Database for high transaction and volume spikes on a website [closed]

I am looking at the IA for a hypothetical application scenario, for example: A high demand application such as an online ticketing website where there can be demand for 100,000 tickets to be ...
1
vote
1answer
149 views

Public Database for Mobile Application

What are the proper steps to hosting a public database. Currently I a building a mobile application with Adobe Flash Builder. I have used Microsoft SQL Server, My SQL as well as WAMP Server. All of ...
2
votes
1answer
443 views

Apply in a CSV file to multiple databases

Recently, I have been working with a client whom has asked us to provide their dataset for use in a mobile application we are making for them. The requirements for this project include the ability to ...
0
votes
1answer
60 views

Searching through lots of applications

Google search has instant search feature. While you are typing, it finds the pages. Apple.com search box. StackExchange ask question part finds similar questions while you are typing question title. ...
1
vote
2answers
373 views

Questions about Database Design for a Web Application

Consider a web application with 100,000 users. Each user can create blog posts. Assume each user has 100 entries. Would it be appropriate to store all the users in one table, with another table to ...
2
votes
2answers
1k views

Database normalization: Describing trait - foreign key to table, or varchar field with value?

My colleagues and I are having a discussion about the normalization of descriptive traits in the database, such as "status" or "type". Let's call the central table of the discussion "Order". In my ...
1
vote
1answer
382 views

Send a trigger to an application upon a specific SQL Server server usage pattern

I've been dealing with a vendor's unconfigurable application which is, unfortunately, the most feature-complete in its niche. I'm looking to augment its capabilities with on-top screen display. Its ...