3
votes
1answer
267 views

Does blocking always mean open transaction?

This may seem a bit dull question but does blocking always mean that there is open transaction and that may cause transaction log grow to infinity because open transaction prevents log truncation ...
1
vote
1answer
5k views

Differences with using Bind variables in TOAD,sqlplus and SqlDeveloper

I have following example query. variable pStartDateBegin VARCHAR2(10); variable pEndDateFinish VARCHAR2(10); begin select '01-01-2000', '30-11-2011' into ...
5
votes
1answer
332 views

What 'resets' the transaction log

My question might sound rather strange but I'm not really a SQL expert and I can't find the answer.. I'm trying to create a backup plan which creates a full backup twice a day. A differential back-up ...
0
votes
1answer
756 views

Getting the metadata about a Query and a Stored procedure in SQL Server

I would like to get all the names of the columns in a given query [SQL Textual Query] and also the columns that are in the SELECT clause in a Stored Procedure. Is there any ways other than using ...
1
vote
1answer
552 views

Stock management - needs suggestions

I need to create a database which will have below modules: Items [Food items, stationary] Items Stock Management [stock in out] Customers Items Sale Management Issue: The system will have ...
6
votes
2answers
6k views

How to promote an existing index to primary key in PostgreSQL

I know how to make a primary key within a table, but how do I make an existing index a primary key? I'm trying to copy an existing table from one database to another. When I show the table, the index ...
1
vote
1answer
343 views

How to take Snapshot of Restoring Database

I have set up log shipping with my database to make a backup. The backup copy of the database is in a status called '(Restoring...)'. I understand this is to be expected? Is there a good way I can ...
2
votes
2answers
414 views

How do you restore (or check) only the extended properties in a MS SQL Server .Bak file?

We store the version number of our DBs as an extended property. As part of the automated build process, I want to be able to check that the "empty" DB that is part of the build set matches the version ...
3
votes
1answer
5k views

Fixing tables out of sync as reported by pt-table-checksum, pt-table-sync is not working

I have several tables being reported by pt-table-checksum with CRC_DIFF between my master and slave servers using the following commands: $ pt-table-checksum h=master,u=user,p=password ...
2
votes
1answer
534 views

Storing bitsets in PostgreSQL?

I need to calculate reach, grouped by different criterions, and would prefer to keep everything in my database. I'm looking for either a pre-built bitset implementation for PostgreSQL, or pointers on ...
2
votes
2answers
2k views

How To Restore A Replicated Database

I am replicating our live database using transaction replication. This is basically to have a backup copy of our database in the case of server failure. The replicated database is read only, so I ...
1
vote
2answers
174 views

Two master databases for two separate apps

We have two different websites one is hosted in asia datacenter called it asiadata.com and other site is hosted in europe datacenter called it europedata.com. Currently we have only one master ...
1
vote
1answer
4k views

Oracle Script For Getting Long Active Sessions

Is there any script that you could provide for v$session? I seem to be encountering an issue in which my oracle active sessions are filled up. This is when I do SELECT * FROM V$SESSION WHERE STATUS = ...
2
votes
3answers
455 views

New Job and Company uses PostgreSQL

I have used MySQL and SQL server all of my professional career. The company I will be working for uses PostgreSQL. Can someone who was/is in a similar situation please give me some insight on what ...
2
votes
1answer
1k views

Differing results from gv$session

The following query returns no results, yet it seems like it should. SELECT * FROM gv$session where SID = SYS_CONTEXT('USERENV','SID'); In my 11.2.0.2 Standard Edition RAC environment the above ...
2
votes
1answer
89 views

Data Extract and submit across the network

I've been given a somewhat vague requirement regarding a data extract process which I need some help with. I'm fairly new to database warehousing etc. but I will try to explain everything relevant. ...
5
votes
1answer
849 views

How do I have Oracle ASM scan for and repair uncorrectable ECC errors (bad sectors)?

I'm running Oracle ASM (11gR2) with normal redundancy on SATA disks (WD Raptors). This is on a physical standby database, if it matters. Occasionally, disk sectors develop read errors (ECC failures). ...
4
votes
2answers
1k views

How do you use MAXDOP in a View?

I have several views that are used to export data from SQL-Server into .csv files. They are all executed via SSIS packages. Our DBA has decided to set the "Max Degree of Parallelism" to 1 and told me ...
5
votes
2answers
13k views

What is Key Preserved Table concept?

I read in the Oracle Documentation about key-preserved table in Updating Join Views Section. However, I didn't find any simple to way understand it. I hope to receive some simple conceptual details ...
2
votes
2answers
11k views

Improve BLOB Writing Performance in Oracle 11g

I have an application that writes a lot of rows into a table that contains a blob column. The average size of the blob is 3k bytes. Is there any buffer that i can resize to improve inserts into this ...
3
votes
1answer
4k views

Recommended hardware configuration Analysis and Reporting Services

What would be a good way to calculate the recommended minimum hardware configuration for a Windows 2008 R2 64bit that will be running SQL Server 2008 R2 Analysis and Reporting Services? The database ...
1
vote
1answer
157 views

Copying a table while maintaining consistency in Oracle

We have a PL/SQL stored procedure that is called on user demand which takes a copy of another table (ie. drop index > delete (not truncate) > insert > create index) and we've noticed the odd race ...
3
votes
1answer
2k views

Does `Seconds_Behind_Master` show exact Slave Lag from Master?

Does Seconds_Behind_Master always show the correct number of seconds the slave is behind the master? I have also Implemented the mk-heartbeat replication monitoring. It was showing the other result ...
3
votes
1answer
580 views

SQL Globalization - DateTimeOffset

What is the recommended best practice when it comes to storing date/time for an application that needs to support multiple timezones? Which is best ? Use the SQL DateTime data type and insert ...
1
vote
1answer
1k views

How often should I run integrity and consistency checks on SQL Server 2008?

Before updates of our application, I run some checks on the database like CheckAllocations and CheckCatalog, so I know the database is in good shape before the update scripts get executed. What is ...
1
vote
2answers
7k views

Set up a MySQL slave using mysqldump to get the initial data

I have a master database which already has some data in it. The tables in the master database include both MyISAM and InnoDB engines. Now I want use mysqldump to dump the initial data of my slave ...
4
votes
1answer
4k views

What memory should be given to the variables of my.cnf ?

Installing a MySQL server is quite easy. However, after installing, configuring the server is an important task for a DBA. Having 2GB of RAM and 250GB of disk space, how should I tune MySQL server so ...
2
votes
1answer
765 views

BACKUP and RESTORE MySQL Database

I have very specific question. I have seen the instructions on how to backup and restore mysql database using SSH but they barely explain the process when backing up on one server and restoring on ...
1
vote
1answer
99 views

What is QP layer?

From blogs.innodb.com: InnoDB Memcached with Binlog Capability In our earlier Labs release, we presented a MySQL NoSQL solution through InnoDB Memcached Daemon Plugin (see earlier Calvin’s and my ...
3
votes
2answers
3k views

Sort by match of LIKE

I wondering how I can implement SQL to get results sorted by best match of a like predicate. I have 100K articles in the database and when user call some items by part of name. I want to show the ...
2
votes
6answers
911 views

Is normalization process needed?

Well after learning DBMS as a subject i got so many questions in mind. Normalization is one of them. As i learnt it there was a lot more confusion and i found that whatever we do in normalization ...
0
votes
1answer
1k views

SQL Server 2012 Installation Error

I been trying to install SQL Server 2012 on Windows 7 SP1 32 bit. Logged in as Administrator and launched setup. Everything installs fine but SQL Server DB Services fails with following error ...
1
vote
1answer
241 views

What is a better way to keep “user online”?

I'm working on software for social network and I plan it to scale a lot. Actually, I'm updating timestamp column every time user clicks, to be sure they're marked as online. When they do not click for ...
3
votes
2answers
5k views

How is localhost resolved by Oracle listener?

When I o an Oracle test installation on a Windows server accepting mostly the defaults, I end up with a listener.ora like LISTENER = (DESCRIPTION_LIST = (DESCRIPTION = (ADDRESS = ...
4
votes
3answers
450 views

How can I select all online friends?

I'm currently working on a social network software written in PHP & MySQL, and it's all pretty fine, but one thing I'm stuck about is online friends. My tables looks following Users ...
5
votes
1answer
8k views

How to find the date a login password was last changed in SQL Server 2008?

I'm porting stored procedures from Sybase 15 to SQL Server 2008. In Sybase this statement calcs an expiration date by adding a number of days to syslogins.pwdate (Date the password was last changed) ...
11
votes
6answers
3k views

Reasons for disabling statistics auto update?

I just learned that a client company I work for has decided to keep the auto update statistics options off for some of their SQL Servers, and the DBAs manually troubleshooting performance issues when ...
0
votes
1answer
177 views

BI development in Microsoft BI

I need to learn how to create a dimensional modelling for an organisation that do not has a BI tool and BI model. Where can I learn more about BI development that should be used in a company? IT's ...
5
votes
1answer
194 views

Will I need more system resources to run DB2 instead of MySQL?

I need to convert my web application from MySQL to run on DB2. I need to know in advance whether I will need a high spec server to ensure the web application performs at the same speed as it does now ...
2
votes
0answers
227 views

MS-SQL index not using all the available columns as seek predicates

I have a sql query on a large table (>17 million rows) that some times does not populate all the predicates before performing index seek, which results in not filtering out enough rows and slowing the ...
1
vote
2answers
6k views

Connect to SQL Server Management Studio over VPN (Hamachi)

I just got my Hamachi VPN set up. For anyone familiar with Hamachi, I have it set up as a gateway so I'm part of the network when I'm away. Almost everything seems to be working perfectly. I can ...
6
votes
2answers
4k views

Best block/stripe size for log volume?

I know the common recommendation for the data volume in SQL Server is to use 64 KB blocks/stripes, since the I/O is typically done by entire extents. I can't find any good information regarding log ...
3
votes
2answers
526 views

Using all the CPU cores by NDBD and MySQL

We are running MariaDB which is a fork of MySQL with NDB cluster engine. The cluster includes one mysql node and two ndb data nodes. While benchmarking the cluster, we are trying to make a bottleneck ...
3
votes
1answer
251 views

Remote Database Backup [closed]

I am attempting to find a reliable service that does remote MySQL Database Backup. Price is no object, unless it's absurdly expensive. I understand this question doesn't really have an answer, and I ...
1
vote
2answers
152 views

Restore backup in order to write datafile sequentially in disk

I have just come to a new company and we have one database which was created with standard initial size and autogrowth parameters for data and log files (1 MB autogrowth for data / 10% for log). The ...
3
votes
2answers
5k views

How to move the ownership/copy a table from one user to another?

I've been tasked with doing some tidying of our database. I'm not a DBA expert so here I am. (We don't have a DBA expert either). We have a user Old_User and another user New_User. Old_User owns a ...
3
votes
1answer
10k views

Why TRY CATCH does not suppress exception in trigger

I have a trigger on a table (source) that data should be copied to the other one (target) in other database. I am trying to implement custom synchronization process for data: I want that target ...
1
vote
1answer
601 views

SQL Server Database Keeps Semi-Detaching Itself

Forgive me if I am not using all the proper terms but I have databases that will detach themselves from SQL Server. In SQL Server Management Studio the plus sign will be missing next to the database, ...
4
votes
3answers
577 views

Most performant SQL query needed

I'm storing documents with fields that are set in a DataSource table. The document is written to the database as follows: Document table (ID, DataSourceID) Document fields (DocumentID, ...
3
votes
1answer
321 views

How Commit works in a transactional push replication with updatable subscribers

I want to know if in a transactional push replication with updatable subscribers, a commit is only done when all subscribers have succeeded to make it, or if it only guarantees the correct commit in ...

15 30 50 per page