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

learn more… | top users | synonyms (1)

0
votes
0answers
5 views

In a large statically-typed software project with non-dynamic manual sql statements inside of it, how do you verify all the sql syntax?

One of the things I seem to struggle with frequently is the need to deploy a software application to test the database interaction. More often than I'd like, I have a syntax error or typo in my sql ...
-1
votes
0answers
20 views

Webapp that shows a table

I have a C# web app that shows a database table on a webpage. I am not convinced that I'm doing this the best way and am looking for people's opinion on a better way to do this. Here's what I do so ...
0
votes
0answers
24 views

n:m as the only way to store notifications?

I have a user and a notifications table. I want to make sure that every users sees a new notification once and only once. Not more, not less. The intuitive idea is to have a n:m relation table with ...
2
votes
0answers
24 views

How do tablespaces differ in DB2 from databases in MySQL or MS SQL Server?

In DB2, it seems there is a strong separation between what a database is and what a tablespace is. Where as in MySQL and MS SQL Server tablespace and database seemed to be used synonymously. What ...
1
vote
3answers
122 views

What constitutes a good Database System(Java / SQL related)

I've given this so much research but still couldn't come to my own conclusion, before continuing this question I would like to give you a rough idea of my current situation. I'm 18 years old and have ...
0
votes
2answers
43 views

Static and dynamic data : should I use different databases?

Say I am building a website that uses two different types of data : Static : information that will hardly change, like movie awards or world countries names (I want fast access so no external API) ...
2
votes
1answer
36 views

An algorithm for finding subset matching criteria?

I recently came up with a problem which I would like to share some thoughts about with someone on this forum. This relates to finding a subset. In reality it is more complicated, but I tried to ...
2
votes
3answers
92 views

Multiple many to many relations or one option table?

Let's say I have a database of persons who have some properties. For the sake of this problem let's say all of these properties relate as N-N. I can either create two tables for each property (one ...
-2
votes
0answers
14 views

Google App Engine File Upload Error - PHP [on hold]

PHP Warning: File Upload Mime headers garbled in Unknown on line 0 When i am trying to submit form with large data in texarea and uploading image also.
0
votes
1answer
53 views

Best way to deploy database-dependant application

I have always "custom developed" software for clients. This means: Develop the software Install SQL Express on client site Import DB, create DB user, set DB permissions etc. Install software on ...
3
votes
5answers
228 views

Is it useful to keep 'definition' entities in a database vs using an enum?

In a project that I have started working on, the database has a lot of FooDefinition tables which act like an enum. It's a C# project using Entity Framework although that is not central to the ...
0
votes
1answer
52 views

Need suggestion on database development environment [on hold]

I'm in a process of developing a database application that would serve several (> 20) clients though a local area network. Basically, they should be able to access a client application with a certain ...
-2
votes
0answers
28 views

JTree is Only Visible Part of the Time [migrated]

I am trying to populate a JTree from a SQLite data base. When it does show up, the JTree is populated correctly, but is only shows up about half the time. Why would it do this? public class ItemPane ...
0
votes
0answers
42 views

Database auto Increment primary key as a foreign key in another table [closed]

So right now I have one table user with primary key userID, this primary key is cross referenced with another table Sets where userID is a foreign key (the set belongs to the user)- Autoincrementing ...
3
votes
1answer
50 views

optimize human-readable database with index

i need to store a large amount of data - about 10 million entries of the format unique hash (64 chars), value 1 (5 chars), value 2 (9 chars) i will be reading and deleting (but not updating) this ...
3
votes
1answer
121 views

Good way to handle the notification counter like Facebook does

I want to build a similar notification mechanism that Facebook handles. I actually store the user's notification in an SQL table (actually it's a graph database but everybody master RDBMS terms). ...
0
votes
1answer
49 views

Multiple intranet/internet systems partially working on same data - database strategy

We are starting rewritting our apps (Internet portal, millions of unique users and few CRM/ERP systems, few hundred users) and we have a huge decision to make now. We are going to write them mostly ...
2
votes
1answer
106 views

How to model a one-mandatory-of-many relationship

I have following class model that I'm quite happy with: A Whole has a special mandatory Part. Furthermore it has a collection of parts, that contains at least the mandatory part, but may contain ...
1
vote
2answers
251 views

How to update a row in database without ID?

I've got a table with the following structure : Col1 | Col2 | Col3 A | B | C A | C | B E | D | C The primary key is (Col1,Col2,Col3). I get the data in another project and ...
3
votes
2answers
130 views

How are composite tables generally handled when there is no ORM tool available?

I am developing a Windows Runtime Component (C#) to be used in an HTML/JS frontend for a Windows Store App. Now, one of the requests is to have a database on the local system to store metadata about ...
1
vote
4answers
143 views

MySQL Database design - Opinions

Im working on a web Application for our bussiness with my brother. Our application its pretty simple, will be develop with php and mysql. Clients and providers ABMs Articles Inventory (we do not ...
1
vote
2answers
93 views

Databases and the single responsibility principle

Can the single responsibility principle be applied to databases? relational databases I mean. I'm asking this because a typical database will have several tables and we may find something like that ...
0
votes
1answer
70 views

Locking database records

What I have right now: A table with lot of records. About 200 users can select a record according to some rules based on the data in each record. There is a high chance that 2 or more users will ...
-2
votes
1answer
69 views

Should I pass the database access class around or query the database and pass the results? [closed]

Bog standard application, but I'm new to databases. I have a wrapper class around the database, and I can see what looks like two sensible ways to structure procedures viewing the data from the ...
1
vote
3answers
100 views

Let applications share a database or keep them in sync with web services?

We have decided to build separate applications for user authentication and user management. The reason is that the the former is a "this just needs to always work, and do so instantly" style service, ...
12
votes
7answers
1k views

Why shouldn't you develop on production database? [duplicate]

I need help with organizing my arguments for why it's MADNESS to develop against production data. Backstory: I started working here six months ago and I noticed we're developing directly against ...
0
votes
1answer
46 views

Should I persist notification before or after publishing it through Redis pub/sub?

I'm implementing a mechanism to notify a group of users about newly inserted blog comments. The architecture uses the Redis Pub/Sub mechanism. By definition, the pub/sub mechanism aims to propagate ...
2
votes
2answers
93 views

Should I be using a composite key for this table?

My database is going to store words, so the Word table is the most important. The Rhyme table lists which words a particular word perfectly rhymes with. It consists of three fields: RhymeID - primary ...
0
votes
0answers
38 views

Connection Pooling

As an example, I am using PostgreSQL with an application-layer connection pool, such a a JDBC connection pool. The specific JDBC connection pool is not important. My question is more about the actual ...
0
votes
0answers
28 views

How to test for performance or locking issues of sharing a database with another app

I have a typical Spring/Hibernate Tomcat webapp that has a user_info table. I’m trying to create another webapp that will do CRUD actions on the user_info table. I'm considering sharing the same ...
11
votes
4answers
308 views

Database design - Store state or compute state every time?

Let's say I have a relational database application and a "user" object and a "message" object. Now I want to show the number of unread messages to this user. What's the best way to archive this? Do I ...
0
votes
0answers
47 views

Save database changes in service layer or controller mvc .net

I have recently been using a service layer to abstract away alot of the business logic of my application. However I've come into an issue where I'm not sure what is best practice on doing the actual ...
0
votes
2answers
89 views

Guidance on connecting a common database to several instances of the same application [closed]

I'm looking for advice regarding a future development of mine, concerning a application that may be run in several machines that need to use and manipulate the same data. As this sounds somewhat vague ...
0
votes
0answers
25 views

What are the memory-management capabilities of MySQL + JDBC (in light of autonomic computing)?

I'm interested in implementing some kind of autonomic-computing functionality using MySQL. By autonomic-computing I mean roughly some failsafe abilities, whereby the application appears to be at least ...
2
votes
3answers
60 views

Should custom data elements be stored as XML or database entries?

There are a ton of questions like this, but they are mostly very generalized, so I'd like to get some views on my specific usage. General: I'm building a new project on my own in Django. It's focus ...
1
vote
2answers
83 views

How can you predict the time it will take for two processes in two different machines in a cluster to communicate?

I am trying to develop a computing application which needs a lot of memory (>500gb). Buying a single machine for that is overly expensive. I can, though, buy ~100 small instances on Digital Ocean or ...
0
votes
0answers
59 views

Appropriate design / technologies to handle dynamic string formatting?

recently I was tasked with implementing a way of adding support for versioning of hardware packet specifications to one of our libraries. First a bit of information about the project. We have a ...
1
vote
1answer
47 views

storing map template in database

I am working on an application that displays choropleth maps. These maps are of all different types, some display state by county, country by state/province, or world by country. How should I ...
0
votes
0answers
55 views

Converting large files in python

I have a few files that are ~64GB in size that I think I would like to convert to hdf5 format. I was wondering what the best approach for doing so would be? Reading line-by-line seems to take more ...
-1
votes
1answer
66 views

Storing a looong lookup table

Background The product i am working on has a very long lookup-table. the table contains static data and cannot be auto generated. there are about 500 rows and 10 columns. columns have mostly integers ...
3
votes
1answer
102 views

Synthetic database records

Assume we are getting some statistics from a customer which we analyse and we send our comments to the customer. Now, the customer tells us that the statistic they computed between January and March ...
0
votes
2answers
57 views

Is it good practice to keep 2 related tables (using auto_increment PK) to have the same Max of auto_increment ID when table1 got modified?

This question is about good design practice in programming. Let see this example, we have 2 interrelated tables: Table1 textID - text 1 - love.. 2 - men... ... Table2 rID - textID 1 - ...
0
votes
1answer
153 views

Inserting data to database from Android

I have to build an application where the requirement is that my clients will send data from their Android device and I have to save that data to a database. I have done the part of coding that ...
0
votes
1answer
96 views

Can I use access used by Visual Basic for building a database [closed]

I am the only programmer where I work (summer job) and I am a student with only a few years of programming experience. So I was asked to build a database and I am very excited about this project ...
2
votes
0answers
54 views

Minimal set of critical database operations

In designing the data layer code for an application, I'm trying to determine if there is a minimal set of database operations (both single and combined) that are essential for proper application ...
3
votes
1answer
94 views

End user query syntax?

I'm making a command line tool that allows end users to query a statically-schemed database; however, I want users to be able to specify boolean matchers in their query (effectively things like "get ...
27
votes
4answers
4k views

Is backing up a MySQL database in Git a good idea?

I am trying to improve the backup situation for my application. I have a Django application and MySQL database. I read an article suggesting backing up the database in Git. On the one hand I like ...
0
votes
1answer
125 views

Keep user and user profile in different tables?

I have seen in a couple of projects that developers prefer to keep essential user info in one table (email/login, password hash, screen name) and rest of the non essential user profile in another ...
1
vote
1answer
41 views

Ticket/Raffle DB schema

I'm working on a project that, when all boiled down, is essentially a raffle. The twist is that due to the way we've set the ticket value, a user may be casting 10,000+ tickets. Essentially, a user ...
1
vote
3answers
100 views

Store history in SQL database column

We have a database that stores the process/history of particular machines. What I mean by that is that we have "started", "updating", "shutdown", and so on for all the computers in the company. The ...