0
votes
2answers
1k views

High Disk I/0 Issues

Our database has been giving this error occassionally... "Timeout expired. The timeout period elapsed prior to completion of the operation or the server is not responding. ---> ...
1
vote
0answers
755 views

DDL trigger AFTER ALTER ON SCHEMA behavior

Can anyone please tell me what's going on here: CREATE TRIGGER afr_alt_trig AFTER ALTER ON SCHEMA cols ora_name_list_t; BEGIN IF (ora_dict_obj_type = 'TABLE') THEN select column_name bulk ...
0
votes
1answer
267 views

Is that possible to group result on 3 months period basis?

I am trying to group results by 3 months period starting by the current month as shown below: row1 15 -- This should contain November, September and October row2 25 -- This should contain ...
2
votes
1answer
400 views

SQL Server Full-Text Search: combining proximity term and thesaurus

Scenario I am developing a full-text search over a products table. The full-text indexed field of th table contains a brief description of the product, the name of the category and the product code. ...
0
votes
1answer
82 views

Is it any good for performance to have master and slave on the same server

There are similar questions on this site, but they mostly cover server failure and data backup aspects. I'm concerned only as far as query performance. If master and slave share the same resources, ...
3
votes
2answers
158 views

Mongodb restrict access on collections level

I'm building a backend system using MongoDB. Now I want to restrict access on certain numbers of database collections to this system. For example I have users, admin_users, pageviews and I want this ...
1
vote
1answer
1k views

Store equations/formula in mysql db table

I want to know what is there a way for storing equations or formula in a DB column. Below is the table where I am storing the machines details(master table). But the last column is what I am worrying. ...
0
votes
2answers
191 views

mysql need help optimizing query

I have a table containing servers logs, and another table containing rules to match certain and drop them. The logs tables contains around 1 million rows, and there are about 20-30 rules. The ...
3
votes
2answers
128 views

Is it suitable innodb_buffer_pool_size for MySQL Master-Slave

I am wondering how to decide the value of innodb_buffer_pool_size for my Master-Slave style database. I have a set of MySQL, 1 x master + 1 x slave. As I know that the innodb_buffer_pool_size is ...
0
votes
1answer
93 views

How to restore SQL Server database to a specific day? [closed]

Suppose I have an SQL Server 2008 which is installed on windows 2008. There is a db MyDb under the instance. MyDb is have full backup every night. Because of storage space on hard driver, only 7 days ...
3
votes
2answers
10k views

SQL Server 2012 Express with Reporting Services

Everywhere I search for SQL Server 2012 Express with Advanced Services, I ended up with this link, http://www.microsoft.com/en-us/download/details.aspx?id=35579, and every time I install it, I do not ...
1
vote
2answers
8k views

How do I get the difference in minutes from 2 timestamp columns?

Can't seem to figure this out. Just need the difference in minutes between 2 oracle timestamp columns. END_TS START_TS ...
1
vote
1answer
654 views

Removing Secondary Replica from SQL Availability Group Causs Large Log File

Due to an unforeseen hardware error, I had to take our secondary replicas down for maintenance. This was really due to a storage issue and, it was decided at a higher level, to purchase a new storage ...
0
votes
1answer
169 views

How to get names form 3 different tables

I have 4 tables to proceed. In table A I have the parameters of columns in tables B,C,D and the names are there. TB_A ...
0
votes
1answer
44 views

Unable to login to MySQL with new user

I currently have a MySQL database which I have added a new user (abbvs) to identified by a password. The users I have: mysql> select user,host from mysql.user; +-------+-----------+ | user | ...
1
vote
1answer
3k views

PG: permission denied for relation <table>

I have ran the following SQL: CREATE USER bspu LOGIN; CREATE DATABASE bsp OWNER bspu; GRANT ALL PRIVILEGES ON DATABASE bsp TO bspu; \c bsp CREATE TABLE users ( id SERIAL PRIMARY KEY, ...
3
votes
3answers
214 views

Joining and filtering two sets of the same table

I guess this is an easy and stupid question. Consider this MySQL purchase table (where p_id is autoincremented): +---------+-------------+---------------+---------+ | p_id | item_id | user_id ...
4
votes
1answer
127 views

SQL Server's BACKUP DATABASE - how to access the original exception?

DECLARE @DbName SYSNAME; SET @DbName = 'MyDatabase'; BACKUP DATABASE @DbName TO DISK = 'C:\MyDatabase.bak' WITH INIT, NAME = 'MyDatabase-FullBackup', STATS = 5; This, sure enough, ...
0
votes
1answer
159 views

Complex Oracle SQL to sum data

I am building a SQL query in Oracle 10g that needs to sum overtime hours for the base table, but needs fields from the parent tables as well. I am looking for the fastest way to build the query. The ...
1
vote
1answer
852 views

SQL Server performance for tables having large number of columns [closed]

I have a requirement where I need to create a table with about 600 columns. Out of 600 columns about 200 columns will be XML columns. Other column will be of other datatypes such as int, varchar, ...
1
vote
0answers
108 views

Migrate from Interbase to MySQL

I need to migrate a big database from Interbase to MySQL, I'd like to have suggestions about free and non-free tools to perform this task. I've found this one: ...
4
votes
2answers
392 views

SQL Server 2012 autoupdate statistics default behaviour

I found, that since SQL Server 2008 R2 there is a trace flag 2317 available. It turns on dynamical autoupdate statistics threshold, instead of default threshold of 20%. So, it greatly improves ...
-1
votes
1answer
83 views

MySQL Replication

i try to search around the internet to find out what's a "Master -> Slave" Replication of MySQL want to do? Can sombardey maby explain it for me? what i can read is what happen are when i have a ...
0
votes
1answer
103 views

mongodb on-premise: will it work?

We are planning to package MongoDB-PostgreSQL hybrid solution in our application that will be deployed on customer site on-premise. It will be packaged as a software virtual appliance. Our reason for ...
2
votes
5answers
3k views

Autogrowth - Percentage Use?

Is it best not to use Percentage file growth for autogrowth settings? The below recommends using percent value growth for databases under 500GB but is this recommended? ...
0
votes
2answers
5k views

MySQL relay log corrupted, how do I fix it? Tried but failed

A MySQL v5.1.61 relay got corrupted when the machine suddenly shut down. I tried to fix it but it didn't work. — How do I fix it? Did I do something wrong? As far as I've read, corrupted MySQL relay ...
1
vote
1answer
194 views

Using OLE DB Source SQL command vs desinging the query using the object tools

In SSIS, we can use the OLE DB Source SQL command to run a T-SQL script on the database and then use the output as the source. For example the a complex query can be wrapped in the OLD DB source SQL ...
1
vote
3answers
582 views

Normalization: 'zip code' as a primary key

I've seen frequently that you should not have all address fields (zip, street, city, state, country, etc) in the same table as your user info table (pk_id, name, email... ). This would be in ...
0
votes
1answer
1k views

How to set up simple database replication using WAMP server?

Just need a little help here about replication. I have an intermediate knowledge in Mysql. And I can't find any simple solutions on web how to establish a database replication in Mysql. All I need to ...
0
votes
2answers
63 views

Amount of memory used by postgres

I am curious as to whether the performance of postgres depends on the amount of RAM available. i.e. will postgres performance(during reads) on several runs get affected by the amount of RAM that is ...
0
votes
1answer
70 views

Creating a MySQL Trigger

I want to create a trigger such that whenever a user is inserted in TABLE A(userid,type) then his "userid" along with some predefined value, depending in his "type", is inserted in TABLE ...
1
vote
1answer
383 views

How to run stored procedure in another database on the same server using a different login?

I have 2 databases (A and B) on the same server. Database A has user ua defined, and database B has user ub defined. I have a stored procedure in A, running as ua, that needs to run a stored ...
1
vote
0answers
207 views

Does a high CPU usage -say 98%- necessary mean the database will be slower?

I have 4 python scripts each running in their own virtual machine. The scripts are accessing a central postgresql database. All scripts are reading from the same table but posting to different tables ...
1
vote
1answer
212 views

Precautions when designing database schema if tables are going to have billons of rows

I am about to start work on telephone dictionary kind of project. Its confirm that there are going to be billions of records in dictionary table, and each entry from this dictionary table may have ...
0
votes
2answers
803 views

Join in same table

I have a table employee +--------+----------+------------+ | emp_id | emp_name | manager_id | +--------+----------+------------+ | 1 | abc | 2 | | 2 | pqr | 3 ...
1
vote
1answer
2k views

Select next and previous rows

I have the following table: CREATE TABLE post ( id bigint primary key, thread_id bigint, is_notice boolean, title text, content text ) I display the list ...
0
votes
1answer
190 views

Making the tables with db generalization [closed]

Can anyone tell me what will be the best way to make the tables for the following diagram: I was thinking about this: videos ------ - id - title music_videos ------------ - id - video_id ...
12
votes
2answers
1k views

I Need to Shrink My Database - I just freed a lot of space

This question is asked in various forms here but the question boils down to: I know shrinking a database is risky. In this case, I've removed so much data and I'll never use it again. How can I ...
2
votes
1answer
688 views

How much free space do I need for mongoDB? and how to reclaim lost space?

I ran out of disk space on my mongo database. I saw it and dropped some collections (120 out of 1700 i had). And ran db.compact(...) thinking it would release free space. well, that was a stupid idea. ...
0
votes
1answer
2k views

Oracle 12c on Ubuntu 12.04

I just installed oracle databse 12c on an ubuntu 12.04, i followed this tutorial ...
0
votes
0answers
121 views

How much free space do I need for mongoDB? and how to reclaim lost space?

I ran out of disk space on my mongo database. I saw it and dropped some collections (120 out of 1700 i had). And ran db.compact(...) thinking it would release free space. well, that was a stupid idea. ...
0
votes
0answers
102 views

Can maintenance plans be used in SQL Server multiserver (Master-Target servers) administration?

Since I failed to configure SQL Server 2012 Multiserver (Master and Target Servers) administration, I am eager to understand whether it (setting Master and Target servers) would permit to send from ...
1
vote
0answers
1k views

How to debug problems with SQL Server multiserver (Master and Target server) administration?

I've tried to set Mater and Target Servers on various cobinations of SQL Servers 2012 R2 on Window Server 2008 R2 and Windows 7 machines but always getting one or 2 of the following errors during ...
1
vote
1answer
1k views

How bad is query plan pollution (too many equivalent plans in cache)?

Question currently affects C#/.NET, DB access based on ADO.NET and SQL Server 2008 R2, but I think it applies to other databases as well. I noticed some old modules of a system have non-optimal SQL ...
0
votes
0answers
45 views

Should triggers be used as an extra precaution to enforce business rules? [closed]

I'm new to SQL Server, and I was wondering: how often do DBA's use triggers to enforce business logic? As long as your security is tight and no user has db_datawriter (or some other all-writing ...
0
votes
0answers
44 views

How to do pivot for a particular result?

In one of my tables I have a list of users. In another table I have ProcessName, Count, RealName(UserName). Now I need the output in the form of: ProcessName OverallCount ...
0
votes
2answers
3k views

How long will it takes to rename table

How long will it takes to rename table with a size of 219 GB? This is the specification of our server: Memory: 65 GB Available disk space: 266 GB mysql Ver 14.12 Distrib 5.0.77 Sorry for the ...
1
vote
4answers
6k views

how to write conditional where clause query

Hi I want write the mysql query conditionally. I am basically using the Wordpress, please have a look at my same tables. tbl1 id name 1 A 2 B 3 C 4 D 5 E tbl2 id post_id key ...
-1
votes
1answer
382 views

How can I detect which indexes are being rebuilt offline and how long?

The rebuild of indexes takes appr. the same 55 min. with both "Do not rebuild indexes and "Rebuild indexes offline" "For index types that do not support index rebuilds" with "Keep index online while ...
2
votes
1answer
68 views

Slony Replication: Will data eventually be 100% replicated if daemon dies for long period?

I am using Slony to replicate a Postgres database. If my slony daemon exits for whatever reason, and doesn't start up hypothetically until 1 month later, will all the data that has accumulated in the ...

15 30 50 per page