Microsoft's SQL Server is a relational database management system (RDBMS) that runs as a server providing multi-user access to a number of databases. It originated from the Sybase SQL Server codebase, which is why both products use the extension of SQL called Transact-SQL (T-SQL).

learn more… | top users | synonyms (2)

2
votes
2answers
333 views

Advantages of Database Snapshot

Can someone please highlight the advantages of Database Snapshot in SQL2008. I read some where that "When a Database Snapshot is created, SQL Server doesn’t allocate space on disk equivalent to the ...
2
votes
0answers
328 views

SQL Server 2008 R2 - Deadlock Trace, Need Help Understanding It

I really need help on understanding this deadlock, i've already replaced the values, mind if anyone helps me interpreting where my deadlocks are coming from? What does e_waitpipegetrow mean? btw, i'm ...
9
votes
1answer
3k views

How to manage 3.1 billion rows of data?

I am currently tasked with implementing a storage schema for a relatively large amount of data. The data will primarily be accessed to determine a current data point value, but I am also required to ...
2
votes
0answers
92 views

SQL Server Online Training [closed]

I recently took an intro class for MySQL from www.oreillyschool.com and it was very helpful. The next class they offer is administering MySQL but I currently work with SQL Server. The first class was ...
6
votes
2answers
337 views

SQL Server Select Count READ_COMMITTED_SNAPSHOT QUESTION

I seem to be getting a lot of deadlocks when doing select count(*) on a particular table. I have already changed all the required parameters and made them into row only locking. I've also changed the ...
4
votes
1answer
4k views

Safe way to truncate SQL Server Error Log

We are running out of space. What is the safe way to clear the error log?
1
vote
0answers
39 views

Query Regarding Database Instance not proper

Please sort out one issue regarding SQL Server instances. I have one instance of SQL Server named 'Test\Connect' and other one is 'local' by default. So the issue is when I connect to local and ...
2
votes
0answers
362 views

Tables not shown in SQL Server Enterprise Manager

For some reason 3 tables which are clearly in use by the application are not listed in the Tables view in SQL Server Enterprise Manager. It's SQL Server 2000. When generating a diagram, a popup ...
0
votes
1answer
279 views

SQL Server 2000 export database to csv

I need to move an SQL Server 2000 database to MySQL. I'm running into several complications. I'm no expert on SQL Server. To get going I'd like to have a csv-dump of structure and data. First issue, ...
4
votes
2answers
3k views

Transaction and Try-catch in SQL Server Job

We have DML operations in each step of a SQL Server job. To ensure the update/insert will be rolled back in case something goes wrong, I have wrapped the data modifications of each step in TRY CATCH ...
0
votes
1answer
231 views

Is this schema usable for multi-tenant clients?How to remove multi-cascade paths?

I am newbie to database design. I want to build multi-tenant application that will have the following schema for its data: School(*schoolid*, schoolname, schooltype); ...
6
votes
2answers
256 views

Why would a SELECT INTO cause an arithmetic overflow?

I am doing this SELECT * INTO table1 FROM Table0 I get an arithmetic overflow on a datetime column (error converting to smalldatetime), however the destinations schema that got created has a ...
3
votes
1answer
2k views

Does this mean the 'public' has full select, insert, update, and delete access?

I'm trying to create a new DB user in SQL Server 2008 R2 that can only select from one SQL View. But no matter what I try when I login as this new user I can select from any table. I ran this query: ...
0
votes
1answer
86 views

Is it possible to use Native Clients from previous releases to connect SQL Server 2012?

Is it possible to use SQL Server Native Clients from previous SQL Server releases (e.g. SQL Server 2008 R2 Natice Client) to connect SQL Server 2012 database?
2
votes
0answers
452 views

Network issues with sql server

There are two servers on co-location. First is Windows Server Standard 2008 R2 SP1. Second is Windows Server 2012 + Sql Server Standard 2012 SP1. First server has a task with a report against tables ...
6
votes
2answers
6k views

SQL Server gets slow over time until we have to restart it

We have a database with a mixed OLAP/OLTP workload. The queries are quite ad-hoc and are dynamically created in the mid-tier application server. When we start the server, the performance is quite ...
0
votes
1answer
294 views

SQL Server Job logging best practice

To be able to design a robust Job in SQL Server, we need to have log for each step of the job. I know there are different options available which help us for troubleshooting a job, but what if we want ...
2
votes
3answers
324 views

Performance impact of Splitting Table across files

EDIT: I think the original question (below) was not worded very well, and probably caused confusion. The basic question is: If I have a SQL Server 2005 database using a single .mdf file and I change ...
2
votes
0answers
1k views

Unable to open BCP host data-file error

Having problem using BCP via xp_cmdshell. I exported the table data to a file as .dat but when I try to import the file to a new table, I am getting the below error. The SQL Server service and the ...
2
votes
2answers
83 views

Log shipping and log file: Can the log on the master or slave every be truncated/shrunk?

SQL Server 2008, standard log shipping setup (well, using redgate, but it is a pretty normal flow). On the replica, the log file is pretty big. Wondering if on the backup/replica servers it is OK to ...
2
votes
1answer
283 views

SQL Server Plan Guide vs Plan Freezing

I am bit confused with terminology as official Microsoft SQL Server documentation including BOL refers to plan guide the one you create using sp_create_plan_guide proc. Does plan freezing is same ...
0
votes
1answer
576 views

How to split the comma separated list in the stored procedure

I am working on small module in which we pass the column name as comma-separated string to a stored procedure. In the stored procedure, we want to separate the column names out.
1
vote
3answers
10k views

Max connections SQL Server Express could have?

I have SQL Server 2005 Express edition installed on one of my client's machine, and lots of other users are also connected to that SQL Server through the C# application that I have provided them as an ...
2
votes
2answers
130 views

Rebuilding system and tables, should I change primary key to int?

I am in the process of rebuilding a current system (orders, invoicing, payments, Vendors, etc), which includes normalizing the current tables with more tables and lookup tables to spead up ...
8
votes
1answer
3k views

Upgrade SQL Server 2005 to SQL Server 2012

I have a test environment set up with the following: Virtual Machine (Hyper-V) Windows Server 2008 R2 SP1(x64-bit) Windows SQL Server 2005 Developer Edition SP4 (x64-bit)(default instance name) 1 ...
3
votes
2answers
153 views

Proper Index for WHERE X <> 1 AND Y <> 1 ORDER BY Z

I have a relatively large table that is accessed in exactly one way, by exactly one query (on the read side). The query filters the table by two columns (both bit), and sorts by a third column (an ...
1
vote
2answers
912 views

Changing field length when foreign keys reference primary key field in table

I have a situation where a number of foreign keys are referencing a column in Table "A". I would like to change the length of the column in table "A". What is the best way to accomplish this in SQL ...
4
votes
1answer
283 views

Large Transaction Log Backups in Service Broker-enabled system

We have a system that uses Service Broker for asynchronous messaging, with a fairly high throughput of messages. We don't really care about the persistent features of SSB in this scenario -- the ...
2
votes
2answers
960 views

How can I capture queries that fail on the SQL Server due to connection failures?

How can I capture queries that fail on the SQL Server due to connection failures? Profiler doesnt seem to capture if there is a connectivity loss. This is scenario: DB server running in Domain A ...
0
votes
2answers
440 views

SQL Server account delegation setup

I am try to run bulk insert command on SQL Server 2008 but I am having issues with the security. after researching via internet, the problem has something to do with account delegation and ...
12
votes
5answers
1k views

Sequential GUID or bigint for 'huge' database table PK

I know this type of question comes up a lot, but I've yet to read any compelling arguments to help me make this decision. Please bear with me! I have a huge database - it grows by about 10,000,000 ...
0
votes
0answers
83 views

Error message installing SQL Server 2005 Enterprise on my Windows 7 Enterprise [closed]

I have a problem installing SQL Server 2005 on my Windows 7 Enterprise 32 bit operating system. The installation never completes. The error log file states I need to have IIS installed (I do and it ...
2
votes
2answers
356 views

How to login in database if we have lost password? [duplicate]

Possible Duplicate: gain admin access to sql express 2008 Is there any idea if we lost our password to login in database using sql express management studio? Is there any place where ...
4
votes
3answers
687 views

SQL Server Log Shipping: Where is the hottest IO during RESTORE LOG: To db or to log?

Using SQL Server 2008. I have used SQL log shipping for years. Works great. Working with a new standby server (recipient of log shipping), I am seeing very poor log restore performance, and wonder: ...
1
vote
0answers
265 views

Powershell to dump database schema to text file

I want to be able to dump a database schema to a sql text file using Powershell. I want this because our DBAs want to be able to do a diff on the file that is committed to SVN. They won't execute it ...
5
votes
2answers
2k views

I lost my database in SQL server 2008 R2

My database suddenly stopped working and from checking the error logs it says that the master database was corrupted. So I tried rebuilding the system database with the command: setup ...
6
votes
3answers
975 views

SQL Server Leaked Transactions

I have a database accessed by around 50 clients via TDS over TCP which does not seem to be releasing log space. The number of processes stays around the expected 50, and some of them are quite long ...
3
votes
1answer
71 views

a query that shows the load request received through GPRS by salesman

I have mobile sales system, in which the salesman sends their stock request in handheld device and through GPRS the data comes to MS SQL database. I need o show a report that shows the which request ...
2
votes
1answer
594 views

Sql server update query locking stages?

Looking at update MyTable set Status = 1 where Status = 0 of course- the where is calculated before the actual update. but does this filtering (where Status = 0) is also inside the lock ? I mean ...
2
votes
1answer
459 views

What causes Transactional SQL Server Replication to need to be rebuilt/re-initialised

In a company I've recently joined we have two SQL Server instances, connected via transactional replication. I'm a developer and hadn't really come across SQL replication before so am a complete ...
2
votes
1answer
877 views

what is difference between last_worker_time and last_elapsed_time in DMV sys.dm_exec_query_stats?

what is meaning of last_worker_time and last_elapsed_time in DMV sys.dm_exec_query_stats and what is differnce between them? when I fire below query SELECT TOP 20 qs.last_worker_time, ...
1
vote
2answers
573 views

New login is created but 'sa' cant assign grant/deny permissions to user in SQL Server 2008 R2?

I created users with login option in security tab in SQL Server 2008 R2 running on windows 7 successfully and grant permissions to : Use dummydb Grant REFERENCES ON OBJECT::vuUser TO nvp GO Use ...
1
vote
0answers
450 views

Cannot remove .bak file

I have a java application that: Reads a .bak file from a windows fileshare and restores it in SQL Server on a remote windows server Does various modifications on the database restored from the .bak ...
6
votes
1answer
478 views

LOCK error after creating a clustered index

I just created a clustered index on a 1MM row table (page and row locking turned on). I now try to run queries and I get this error: "The instance of the SQL Server Database Engine cannot obtain a ...
8
votes
3answers
771 views

I'm using the SQL Server Agent to schedule even non-database tasks - is this a bad idea?

Since I'm a DBA (and in many cases, the de-facto sysadmin), SQL Server is installed on pretty much every server I have to work with regularly. I realized recently that I've been using the SQL Agent as ...
5
votes
1answer
401 views

Inline table-valued function vs inline sql

I'm seeing some odd behavior in trying to tune an inline table-valued function. Specifically, if I take the guts of the function and it with the same parameters as I'd have called the function with, I ...
3
votes
1answer
688 views

Normalized Table Structure for Logging

How can I normalize a table that has four columns for logging the latest activity for a single record: Created On Created By Modified On Modified By We have dozens of tables, all with these 4 ...
1
vote
0answers
153 views

Distribution Agent running but subscription does not exist?

I have an issue where in my replication topology, the distribution agent is running, and says there are no commands to distribute. However, checking the undistributed commands, it shows there are a ...
1
vote
1answer
97 views

Monitor Sql Server 2000

I was wondering if there is a free tool to monitor state of SQL Server 2000. I would prefer a web tool. I would like to see if some database is accessible, or are there any problems on server, etc. ...
3
votes
2answers
681 views

Cannot generate reports from SQL Management Data Warehouse

I'm running SQL Server 2008 R2 and have installed the MDW on one server and have a Data Collector collecting and uploading the server activity, query results, and Disk activity data to the MDW. When I ...