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
1answer
105 views

Repair MS SQL Database

Can anyone give me a complete guide to verifying/repairing a MS SQL database. At the moment our backup is failing on the Solarwinds database saying the database NetPerfMon is corrupted (we are using ...
0
votes
2answers
24 views

Using UNION (ALL) in a WHILE loop with SELECTto merge the result set for each iteration

When I am looping with WHILE in SQL Server 2012, if I use a SELECT statement it prints the column name for each iteration. Can I UNION all? Here is my sample query: CREATE PROC spGetChar @start ...
0
votes
1answer
71 views
+50

Database/Storage engine suggestion for a project involving heavy inserts?

I am looking into a project which involves large number of inserts daily.I will have a list of user's (for example a user set of 500k ) , for which I need to monitor daily certain activities ...
1
vote
2answers
762 views

SQL Server Replication: “ALTER TABLE ALTER COLUMN” is not propagated to subscribers

We are running SQL Server 2008 R2 SP1 as publisher & distributor, and SQL Server 2005 SP3 as subscriber. The replication of schema changes is activated, and the replication has been running for ...
1
vote
0answers
31 views

Enforce referential integrity between two groups of data

I have two sets of records: A collection of rules. A collection of actions to perform based on those rules. What I'm trying to model is something like this: Multiple rules can be grouped ...
0
votes
1answer
225 views

distributed queries are configured to run in single-threaded apartment mode

I have sql server 2008 R2 64bit Developer's Edition Installed on my machine. And Microsoft Office 2010 Professional 32bit. I have been trying to import some Excel data from an Excel sheet into a sql ...
0
votes
2answers
48 views

Get the first and last names of all employee who entered the project at the same time as at least one other employee

SELECT EmpFname ,EmpLname FROM Employee_m WHERE ( SELECT COUNT (w1.EnterDate) FROM WorksOn_m w1,WorksOn_m w2 WHERE w1.EnterDate = ...
0
votes
2answers
64 views

Cannot Copy Database

I am working with SQL server 2012. I want to copy a database along with all the data. I just want to create a dev DB. I know SQL Server 2012 has a Copy Database... wizard. But when I run that wizard, ...
0
votes
3answers
50 views

How to uninstall SQL server 2012 not showing in control panel's “Programs and features”

I am frustrated to the core. While fixing my Sql Server I've made the situation worse. Here is the problem: initially my master database was corrupted, so the MSSql service was not starting. I tried ...
2
votes
2answers
177 views

SQL server query is slow *without* including execution plan

I have just set up fresh installation of SQL Server 2012 on a new server and I'm experiencing very strange performance problems. Long story short, for some reason not including execution plan makes my ...
3
votes
1answer
534 views

Optimising a query against sys.fn_dblog

Looking for assistance improving a query. This query is used to review the last N transactions in the LDF file and then add some useful information like the user, start time, query text, etc.. Here ...
0
votes
2answers
87 views

Joining tables with one to many relationship

Hi I have a service ticketing system database (SQL Server 2008) which i want to get the hour elapsed for the tickets. One table contained the Ticket number and the created date/time while the other ...
0
votes
0answers
51 views

Two SQL Server databases setup with same .mdf and .ldf files [on hold]

In a SQL Server 2008 R2 instance two databases (the second one being a restore/copy of the first one) have been setup against the same .mdf and .ldf files. How would I go about either deleting the ...
0
votes
1answer
210 views

SQL Server Error - HRESULT E_FAIL has been returned from a call to a COM component

I have a huge 200MB .SQL file. When I try to open this in SQL server management studio 2008, I get the error -Error HRESULT E_FAIL has been returned from a call to a COM component. What could the ...
2
votes
2answers
522 views

Twice job results in sql server, last one is left in progress

I have the job MP - Create CSV which execute a package SSIS in sql server 2008, when I check for the job history I see the result at step 0, I expand and I have 2 results for the step 1. Fist result ...
0
votes
1answer
49 views

When to rebuild and when to reorganize indexes [duplicate]

I have been trying to gather information about rebuilding and reorganizing indexes. From stackoverflow page (How Often should the indexes be re-build in sql-server DB?) i got this query : SELECT ...
0
votes
2answers
34 views

Does leaving a connection open for a matter of seconds cause deadlocks?

I have been testing a system application and have noticed that it is slow when it connects to the database overseas. This is to be expected to some extent, but there is a big difference with the ...
3
votes
1answer
149 views

SQL Script to Drop old AD logins, Inactive SQL Logins and all related Users

Related Question: SQL Server script to delete accounts no longer in Active Directory Whilst the above question points out the rather handy sp_validatelogins procedure, i'd like to extend this ...
3
votes
1answer
72 views

SQL server job has not run and also no entry logged in its history

I have scheduled a SQL job to run daily at 3am in the morning which creates a batch. It has not run today and i am also not able to fathom what's the reason behind its failure. There is no entry in ...
0
votes
1answer
891 views

Cannot create an instance of OLE DB provider “OraOLEDB.Oracle” for linked server

i am having a bit of a linked server problem . I created a sql server linked server and it's been working fine for last 2 years and suddenly not working . SQL Server Microsoft SQL Server 2005 - ...
0
votes
1answer
48 views

How to perform same DML statements on two different servers (Oracle and SQL-Server) simultaneously

I have two servers, Oracle and SQL-Server. I have same database on both the servers. I want to perform DML (insert,update,delete). How can I perform same DML statements on both the servers ...
5
votes
2answers
453 views

“Arithmetic overflow” when initializing SQL Server 2012 replication from backup

I'm initializing SQL Server replication from a backup, by following instructions from here: http://www.mssqltips.com/sqlservertip/2386/initialize-sql-server-replication-using-a-database-backup/ ...
0
votes
0answers
27 views

What's the optimum hardware configuration for a database?(SQL Server) [on hold]

Database circumstances are different from place to place, but there are a few theoretical areas which should prove true for all circumstances. I think it would be great if it is summed up in one ...
0
votes
1answer
1k views

Error on changing ownership of database from Files Page in database properties dialog box

I've restored a database and created a new user(same user from which I've logged in) as db_owner. Now when I wanted to see database diagram got an error Database Diagram support objects cannot be ...
2
votes
0answers
36 views

Adding warning with sp_add_alert doesn't work with “Greater Than” and SQL Server 2014

We upgraded our SQL Server from 2008 R2 to 2014. I want to add a custom warning. USE [msdb] GO EXEC msdb.dbo.sp_add_alert @name = N'MAN more than 1000', @enabled = 1, ...
2
votes
1answer
445 views

what is '#' in create table statement? [on hold]

I have recently seen a statement like: CREATE TABLE #tbl_AR_Data I wanted to know what is the purpose of that symbol "#" (NUMBER SIGN, hash, pound sign) in this statement?
0
votes
0answers
61 views

SQL Server Perfmon % Processor Time unbalanced

I am somewhat of an accidental DBA, and I'm troubleshooting a SQL Server box where performance has been notoriously poor (as reported by the customer). I was not involved in the initial planning of ...
-2
votes
0answers
21 views

Procedure for monthly reports [on hold]

I have table1 which have (empid,inpunch,outpunch,tdate) and another table2 for storing results in form of (empid, 1,2,3,4 ...,30) I need to write a procedure that inserts the inpunch and outpunch ...
0
votes
1answer
99 views

Bidireccional synchronization between a local Sql Server 2005 database and a SQL Azure database using Sql Data Sync

I need to synchronize an Sql Server 2005 database in an SQL Azure database. In other posts I've read that I can do this using Sql Data Sync but I don't know if SQL Data Sync can make the ...
3
votes
1answer
149 views

SQL Server AlwaysOn Error_number 35206

I've joined a Ecommerce business where they use SQL Server 2012 AlwaysOn for HADR and this is the first time I've come across supporting this technology. The Sql Server log on both nodes gets ...
1
vote
1answer
107 views

Partition : understanding files and file groups

We are trying to partition a large history table. Being new to partitioning, I was trying to understand the concept of files and file groups. File groups can be set up in following three ways : 1. ...
10
votes
4answers
5k views

SSMS Tools Pack Alternative

Are there any tools out there comparable to SSMS Tools Pack 2012? The licensing ($30 per machine, $100 for any number of machines... for 3 months) leaves a lot to be desired and I wasn't sure of what ...
0
votes
2answers
407 views

SQL Server 2012 copy database failed

I want to make a copy of database in the same SqlServer . so, When i using the Copy Database Wizard, it throw error: ( I did this steps with a test DB and it works fine !!!!) config: sa user ...
1
vote
1answer
26 views

MS SQL Server 2012: once a day full replication (automatic backup/restore) for reporting

Our company is w/o a DBA, and it has fallen on me (a complete DB noob) to handle some critical database tasks. I'm looking for the best solution for us to be able to "copy" a full database to another ...
0
votes
0answers
17 views

Report Platforms [on hold]

I’m currently reviewing Report Platforms to enhance the reporting functionality that I incorporate into my custom applications. I am looking for a solution(s) that will allow to do the following: ...
1
vote
2answers
80 views

How I can force the TSQL-Developers to use not deprecated TSQL?

I want to avoid the using of deprecated code. Like the new feature Nr. 8 http://msdn.microsoft.com/de-de/library/ms178053.aspx I want to force them to use "WITH" for example, or a semicolon at the ...
0
votes
0answers
28 views

Retrieve SPID For SSRS Request

Is it possible to determine what SPID was created to execute a SSRS report? I am trying to prevent users from running the same report multiple times. So what I was thinking of doing was retrieve the ...
4
votes
1answer
507 views

Slow SQL Server query using a DB2 linked server in virtual environment

I have a problem with a slow query which uses a linked server. Let me list out my environment first and I'll get to the issue: Virtual Windows 2003 R2 server (fresh deployments on XenServer 6.1 ...
2
votes
1answer
182 views

Can I upgrade SQL Server 2008 R2 Standard to SQL Server 2014 Developer?

Is there a migration path to upgrade SQL Server 2008 R2 Standard to SQL Server 2014 Developer? If so, are there any pain points? If not, how would you recommend I proceed? The context of this ...
0
votes
1answer
38 views

SQL Server 2008R2 Migration to new Platform - What Steps Required?

We are migrating our SQL Server 2008R2 instance from one Windows Server platform to another. SQL Server will remain as 2008R2. The new plaform will have more disk space, memory and CPU. I am doing up ...
0
votes
1answer
60 views

Indexes and their uses [on hold]

Index improve performance in select statement, but what is the difference between this create clustered index ix_index1 on table1(col1) create clustered index ix_index2 on table1(col2) and this ...
0
votes
1answer
67 views

Namespacing database names on my server in order to test multiple different SSIS packages

An SSIS package that I'm building has two OLE DB connections, to databases named "core" and "staging". I created test versions of these two databases on my local SQL Server installation. I named them ...
1
vote
1answer
59 views

Use NOLOCK hint when calling table valued function

Suppose the following function: CREATE FUNCTION [dbo].[ufnTest]() RETURNS TABLE AS RETURN SELECT 1 AS Nr My actual function will select actual data from many different tables. I (mostly) understand ...
5
votes
2answers
1k views

Optimisation of complex query - 100% cost index seek?

I'm a c# developer, however I'm quite experienced with SQL. I have had a bit of experience with optimising queries but I've come up across one that has me stumped. The query takes about 3 minutes to ...
0
votes
1answer
309 views

Deleting Record from Linked Table Slow in MS Access

I have a Microsoft Access database that is linked to a SQL Server 2000 backend. It has one form with several subforms, all using information from linked tables. When I try to delete a record from one ...
1
vote
1answer
589 views

Connection to local SQL Server 2012 can be established from SSMS 2008 but not from SSMS 2012

I have two local SQL Server instances running on my local machine. The first is SQL Server 2008 R2 Enterprise Edition (named MSSQLSERVER) and the 2nd is SQL Server 2012 Business Intelligence Edition. ...
1
vote
1answer
59 views

Check entry based on entry in another column

Still fairly new to databases and SQL, so bear with me. I'm trying to check whether or not data can be inserted depending on data in another column, create table Table1 (PaymentType varchar(5) ...
0
votes
0answers
30 views

Need some ideas for class/certification for Data Warehousing/Big Data

I am an ETL developer at a large company and have the opportunity to attend some training. I get to pick a few class's/certifications. What would this community recommend as best for someone that ...
1
vote
1answer
31 views

Does SQL Server 2014 Express, with Advanced Services, actually support full text search?

I've installed SQL Server 2014 Express edition, with advanced services. I was hoping to try out the full-text search features. I read here that full text search is supported by the 2014 express ...
0
votes
1answer
39 views

Are these linked server queries susceptible to SQL injection?

I'm using a stored procedure to generate a create table script on the fly based on parameters passed into it. I am validating that the server exists, and then validating if the table exists in the ...