Most Popular
1500 questions
31
votes
4 answers
Best way to create a materialized view in MySQL
I am using MySQL 5.6. I am not being able to a create materialized view like I can in Oracle. I have seen one or two solutions like Flexview.
Can anybody tell me best way to create a materialized view in MySQL (auto refresh like in Oracle ) with the…
Bhupendra Pandey
- 561
- 3
- 7
- 16
31
votes
3 answers
What is a deterministic method for evaluating a sensible buffer pool size?
I'm trying to come up with a sane way to understand if the max server memory (mb) setting is appropriate (either should be lower, or higher, or stay the way it is). I am aware that max server memory (mb) should always be low enough to leave room…
Hannah Vernon
- 70,041
- 22
- 171
- 315
31
votes
3 answers
Mnesia: advantages and differences
What are the advantages of Mnesia over major SQL database implementations and how it differs to them?
Can I use the database to hold really huge amounts of data without noticeable performance degradation ?
Yasir Arsanukayev
- 3,145
- 3
- 22
- 30
31
votes
5 answers
CREATE DATABASE permission denied in database 'master'. unable to get the permission
I am making a database in sql server and it shows an error that "CREATE DATABASE permission denied in database 'master'"
I am using the administrator log in itself.
What i need to do?
Please suggest a fix!
Shubhankar
31
votes
2 answers
How to use COALESCE with multiple rows and without preceding comma?
I'm trying to achieve the following:
California | Los Angeles, San Francisco, Sacramento
Florida | Jacksonville, Miami
Unfortunately, I'm getting ",Los Angeles, San Francisco, Sacramento, Jacksonville, Miami"
I can achieve my desired results…
user2732180
- 751
- 2
- 10
- 18
31
votes
1 answer
Why is the speed of executing statements dependent on the network connection?
It looks like the speed of executing T-SQL is dependent on the latency of the network connection against the server. I assumed that if SQL Server has nothing to report back to the client about, it will just execute away until it is done but testing…
Mikael Eriksson
- 22,175
- 5
- 59
- 103
31
votes
5 answers
Is there a "best-practices" type process for developers to follow for database changes?
What is a good way to migrate DB changes from Development to QA to Production environments? Currently we:
Script the change in a SQL file and attach that to a TFS work item.
The work is peer-reviewed
When the work is ready for testing then the SQL…
Beth Lang
- 952
- 1
- 9
- 19
31
votes
3 answers
Foreign key constraint on array member?
Suppose I have a table containing job roles:
CREATE TABLE roles
(
"role" character varying(80) NOT NULL,
CONSTRAINT "role" PRIMARY KEY (role)
);
Suppose I further have a table, users, and each row (a specific user) can have an arbitrary number…
user2965107
- 411
- 1
- 4
- 3
31
votes
4 answers
What steps are necessary to safely restart a machine hosting Microsoft SQL Server?
Are there any special steps necessary to prevent data corruption when restarting a server hosting an MS SQL Server instance?
For example, I recently encountered the recommendation of stopping the SQL service manually. My understanding is that this…
Jon of All Trades
- 5,967
- 5
- 45
- 62
31
votes
1 answer
Designing a platform: one database or multiple databases?
We are building a web platform that incorporates multiple services, each with its own underlying data. These services are being built independently following the principles of Service-Oriented Architecture, but they transact against potentially…
Nick Chammas
- 14,670
- 17
- 75
- 121
31
votes
4 answers
Adding columns to production tables
What's the best way to add columns to large production tables on SQL Server 2008 R2? According to Microsoft's books online:
The changes specified in ALTER TABLE are implemented immediately. If the changes require modifications of the rows in the…
sh-beta
- 609
- 1
- 5
- 11
31
votes
2 answers
MySQL and window functions
It seems that MySQL does not support window functions.
E.g. the simple: COUNT(*) OVER() AS cnt does not work.
What I am not sure is if this applies to commercial version as well (I assume the community version is limited subset).
If not, how does…
Cratylus
- 1,003
- 3
- 12
- 18
31
votes
2 answers
Using MongoDB and PostgreSQL together
My current project is essentially a run of the mill document management system.
That said, there are some wrinkles (surprise, surprise). While some of
the wrinkles are fairly specific to the project, I believe there are
some general observations…
chucksmash
- 545
- 1
- 6
- 9
31
votes
2 answers
How can I determine the size of a dump file prior to dumping?
How can I determine or estimate the size of the SQL dump file prior to using something like mysqldump?
Micah Bolen
- 435
- 1
- 5
- 7
31
votes
1 answer
Trigger in combination with transaction
Suppose we have the following situation:
We have a table (let's say Table_A), wich has a trigger on INSERT. The trigger job is to update some rows in table_B based on the inserted values in table_A.
Now, everything is ok when we simple insert a row…
veljasije
- 815
- 2
- 11
- 20