1
vote
1answer
957 views

Can operations in a loop cause table locks?

I know a bit about locking etc, that when a transaction is working on a table, if it is altering a certain amount of data it might try and lock the entire table (I'm sure that is over simplified, but ...
3
votes
3answers
4k views

MySQL: selecting arbitrarily ordered rows after a specific id

Please excuse the awkward wording of my title, I'm not quite sure how to phrase what I'm asking. Suppose I have a table like this: id value 1 10 2 40 3 20 4 50 5 40 Running this query: ...
2
votes
2answers
2k views

Oracle regular expression regexp_like

I have simple question. why would : select regexp_like( (select 'https://www.hotmail.com' from dual) ,'(f|ht)tps?:') from dual ; not work?
0
votes
1answer
2k views

Db design for a quiz with variable number of answer choices, and each worth different score in a different category?

I'm working on a question/answer project and having a hard time coming up with a suitable database structure. Each question can have from 1 - "n" answers, and each answer is associated with one of ...
5
votes
3answers
2k views

Maximum number of databases for single instance of PostgreSQL 9

Developing a multicustomer application we plan to use a different database for each customer. But it could be more than 1000 customers (applications). Will PostgreSQL handle it without any problems? ...
0
votes
2answers
2k views

MySQL database backup every day using java code

We are developing a Java web application using Spring, Hibernate and MySQL. I want our application to automatically backup the MySQL database daily; is there any way to accomplish that with Java ...
5
votes
2answers
5k views

Help to understand explain plan in Oracle

I am running a query in some big tables, and although it runs fine even tough is a lot of data, I'd like to understand what part of it weighs on the execution. Unfortunately I am not too good with ...
2
votes
1answer
138 views

postgres 9.1: both md5 and ident on the same connection type?

In pg_hba.conf, is there a way to enable both 'ident' and 'md5' for local connections? Concretely, I am happy to have 'ident' turned on for humans to interact with the database. However, if I set up ...
1
vote
3answers
570 views

query optimization for update nested query IN(SELECT

Can we optimize this? UPDATE TABLE_NOTE SET COL_NOTE_DISPLAY='BLOCK' WHERE COL_NOTE_BIBID = $projectID AND $COL_NOTE_ID IN ( SELECT COL_PILENOTEREL_NOTE_ID FROM TABLE_PILENOTEREL ...
2
votes
2answers
1k views

Issues with uninstalling and re-installing SQL Server 2008 R2

I have installed SQL Server 2008 R2, and was able to login and also create a database and everything. When I was facing some problems with connecting my .NET project with SQL Server, I created some ...
5
votes
2answers
16k views

innodb_flush_method=O_DIRECT vs O_DSYNC performance impact on ext3 with LVM disk partition

In one of my production environment, we have two instances running on a RedHat cluster, with one production instance associated with the cluster. We have 125G main memory with 24G InnoDB buffer pool ...
1
vote
0answers
88 views

MySQL replication backup

How to take MySQL Master-Master and Master-Slave replication backup?. I have setup Master-Master replication with a separate slave for each master on Ubuntu. What happens if, I issue or schedule ...
2
votes
2answers
3k views

MySQL 5.1.63 - using tuning-primer - Table Cache question

tuning_primer says the following: TABLE CACHE Current table_open_cache = 812 tables Current table_definition_cache = 256 tables You have a total of 498 tables You have 812 open tables. Current ...
1
vote
1answer
2k views

MYSQL Social Networking website - Database Design, Data Growth and Hardware

Introduction I have a system around one million users (community based). It has around 6000 groups (fixed , no change). But there is no discussion board for these groups yet. Building discussion ...
2
votes
2answers
117 views

Resume download on DB exporting

I am attempting to export a large database and import it to another PC over the Internet. Sometimes my Internet connection fails resulting in a database export error, causing me to have to restart ...
2
votes
2answers
20k views

Comparing date and timestamp variables in a where clause in a procedure

I have a variable in an Oracle stored procedure of DATE type (from user interface), and another of TIMESTAMP type (database is more precise than what the user would enter in the code that is executing ...
1
vote
1answer
162 views

Does Oracle server installation include client components?

I installed Oracle personal edition on a Windows Server 2008 virtual machine for testing purposes. My intention is to test Linked server functionality with SQL Server. Does Oracle Server installation ...
7
votes
1answer
1k views

Non-yielding IOCP Listener

Does anyone know what `Non-yeilding IOCP Listener' indicates? On of our SQL Servers just had a bugcheck dump: ===================================================================== ...
1
vote
1answer
7k views

Some MySQL slave errors?

Master version: mysql-server-5.5.14-1.el5.remi Slave version: Percona-XtraDB-Cluster-server-5.5.24-23.6.340 Binlog format: ROW based I'm using PRM to setup HA for MySQL. Sometime, MySQL slave ...
1
vote
1answer
2k views

SSIS: “The buffer manager cannot write 8 bytes to file”

We have about 60 or more SSAS cubes on one server. All the cubes have the same structure. Each cube has a different size because each cube has a different underlying data warehouse. However the schema ...
1
vote
1answer
863 views

MySQL Replication Error, can't stop slave

When I run command SHOW SLAVE STATUS\G, I see Slave_IO_Running : 'Yes' Slave_SQL_Running : 'No' What I've usually done to fix this is to run STOP SLAVE; SET GLOBAL sql_slave_skip_counter = 1; ...
2
votes
1answer
595 views

Should I use left join to do my job in this scenario?

What I want to do is to find out the items which appeared more than once in this table: mysql> desc tables; +-----------------+---------------------+------+-----+---------+-------+ | Field ...
8
votes
5answers
6k views

How to search a MySQL database with encrypted fields

Suppose I need to encrypt certain table-fields of a MySQL database. Additionally, I need to search some of those fields I did encrypt. How would one search those fields anyway? Decrypting each ...
0
votes
1answer
1k views

Error restoring backup in sql server. Old server version

When trying to restore a backup file (.bak) to SQL Server installed on my machine, I get the following error (steps that I follow to restore are: Right Click Database ---> Tasks ---> Restore) Error ...
1
vote
5answers
876 views

SQL Server - Database per company. How to query across databases?

We are designing a product that, as per the client's request, must utilize a database-per-company design approach with one shared database holding common data. We are using SQL Server 2012 for the ...
2
votes
1answer
77 views

Preventing concurrent sends of emails from my application

I have a system that sends emails for me and my clients every day in the morning. This process is triggered automatically through access to my website, via an iframe. Often, I receive the same email ...
2
votes
1answer
131 views

I would like to better understand the SQL Server security model in terms of users and groups to possibly replace an XML heirarchy model I am using

I am currently using XML in my database to represent metadata for individual products. I am using the below schema to enter the data. In each sub grouping of fields you will notice the cms_name ...
-1
votes
1answer
391 views

Multiple schema or multiple databases for better performance [closed]

I need to improve the performance of our enterprise .Net search application from the database point of view. The app already has 4 schemas on SQL Server 2008. 2 schemas for front-end operations ...
1
vote
2answers
401 views

Multiple schema or multiple databases for better performance

I need to improve the performance of our entriprise search application(.net) from the database point of view. The app already has 4 schemas on a separate sql server 2008. 2 schemas for front-end ...
2
votes
1answer
2k views

Why is a Star Schema more normalized than a 3NF Schema?

According to Oracle's documentation, third normal form schemas "may require less data-transformation than more normalized schemas such as star schemas". I'm confused, I thought 3NF is the most ...
4
votes
1answer
4k views

Setting up MySQL Cluster on Two Systems

I am attempting to setup a MySQL Cluster. I have the folllowing setup one management node two data nodes another machine on which two more nodes reside Below is the config.ini file: [ndbd ...
21
votes
4answers
13k views

Measure the size of a PostgreSQL table row

I have a PostgreSQL table. select * is very slow whereas select id is nice and quick. I think it may be that the size of the row is very large and it's taking a while to transport, or it may be some ...
6
votes
1answer
7k views

Mirroring - Server network address cannot be reached

I have SQL Server 2008 R2 Installed. It contains three instances. Default (MSSQLServer) First Instance Second Instance All these are Log On as Network Service.. Default Instance is Principal ...
1
vote
1answer
1k views

$nearSphere returns too many data. What am I missing? Am I wrong? Is it a bug? Does other see the same thing?

I noticed that $near and $nearSphere returns completely different data and I got suspicious. After all, when latitude is near equator it sphere distance shouldn't differ a lot from euclidean distance. ...
13
votes
2answers
8k views

Broken NTFS Permissions for MSSQL$SQLEXPRESS

I have been "securing" our database server. To do this I removed some permissions from the folders that the SQL Express install created. D:\SQL D:\SQL\Data D:\SQL\Backup etc.. I kept the ...
2
votes
1answer
801 views

Renaming the Data Sets in SSRS

What is the easier way to rename the Data Sets in completed SSRS report? I have created a report in BIDS 2008 and now for some reasons I have to rename the Data Set names, but it seems that renaming ...
0
votes
2answers
2k views

MySQL how to release memory used up by SELECT

I executed an INSERT IGNORE combined with SELECT from large table. The SELECT took up 16GB of memory and went into SWAP before I terminated it with CTRL+C. INSERT IGNORE INTO sid(sid) SELECT sid ...
1
vote
1answer
499 views

How do I query based on percentages of a subset of values?

I have a table with a column named Type that can have some set of values. For instance, A, B, C, D, etc. Behind the scenes this is mapped to an Enum. I need to query this table to get a percentage ...
1
vote
2answers
257 views

Can graph databases be easily distributed?

I have never worked with graph databases such as neo4j, I would like to know if they support easily replication and clustered distribution as well as key-values databases, or if there inherent ...
6
votes
4answers
16k views

How to list all views in SQL in PostgreSQL?

How do I list all views for a database using an SQL command in PostgreSQL? I would like something similar to output of the psql \dv command, but preferably just a list of view names. e.g., SELECT ...
1
vote
3answers
1k views

How do I copy a view from one server to another?

I want to copy a view from server S1 --> Database D1 to Server S2 --> Database D2. I generated the script by right clicking the database(D1)--> tasks--> generate script. However, when I execute this ...
1
vote
3answers
3k views

Workarounds for setting default schema for domain group?

I am currently working on a project for a client, they have asked me to change the database from Oracle to SQL Server. So we migrated the database across to SQL Server 2008, when this was migrated ...
2
votes
1answer
4k views

How do we free up disk space from allocated namespace? / ORA-03297

We are running out of disk space. The server has a 420 GB HDD, and runs a Microsoft SQL Server and an Oracle Server(10g). The Oracle server uses up to 315 GB space. We have just loaded a 100GB ...
3
votes
1answer
549 views

Grant User Permission To Restore Database And Access that database in sql server?

I want to create a user having db_create, db_restore server roles and will be db_owner of that database. But there is only 1 server role available, that is db_creator, which can create database and ...
1
vote
4answers
4k views

mdf,ldf file attach problem?

I've created one database on my local system. consider database name is test. This database primary files are test.mdf, test_log.ldf. and contains ndf files too. Then i've stopped sql server service. ...
0
votes
4answers
69 views

Copy my data from a existing db to a new db

I have a database which has my data's that I have been working for months. Now, I want to delete that db. What concern's me is that the data's that I have might come in handy in the future ...
7
votes
1answer
614 views

CATCH block is triggered when it should not

On my neverending quest for shooting myself in the foot with save transaction I seem to have found even more ways to fulfill the quest purpose. The save transaction clause itself this time is out of ...
1
vote
2answers
482 views

How do I run a SQL Server 2005 job on Windows 7?

I have Windows 7 and SQL Server 2005 Version 9.00.1399. I can successfully create an SSIS Package, however I am unable to execute it successfully as a scheduled job. When I run the job, SQL Agent ...
2
votes
1answer
1k views

MySql - alternate of auto_increment on multiple columns

Since auto_increment on multiple columns is supported in MyISAM engine only and I can't use it because of its drawbacks (table lock, slower writes, no-transacts etc), I am looking for an alternative. ...
1
vote
1answer
14k views

“Operand type clash” with DATE column

I enter the following command into the SQL Server Management Studio insert into testtable ([product_name], [price], [expire_date], [expire_time]) values ('Teapot', 10.00, 23/12/2012, '12:35:00') ...

15 30 50 per page