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
110 views

How can I filter an extended event by database in SQL Server 2008 R2

If I do an extended event session like this in SQL Server 2008 R2: CREATE EVENT SESSION [Query tracing] ON SERVER ADD EVENT sqlserver.rpc_completed ( ACTION(sqlserver.sql_text) ...
0
votes
0answers
36 views

Saving replication latency for monitoring purposes

I have SQL Server 2012 Enterprise edition, transactional replication. many servers, many DBs. This morning I come to the office and been told the latency on some databases was about 30 min behind. I ...
2
votes
2answers
114 views

SQL Server DROP Database which is in a long roll back process

I have a DataBase that is taking very long to rollback a transactions. Which could be normally because it is rolling back a hugh amount of data. However I have the scripts to create the DB again and ...
0
votes
2answers
43 views

What is the Query to display the failed sql jobs

What is the Query to display the failed sql jobs,so that I can get all the failed job information with one query
0
votes
2answers
73 views

what could be the Best practices with very very large amount of data [closed]

I have a question on building a solution.I have a few txt/csv file having huge amount of data approx 30000000000 rows .By size they are 1.5 TB.The tables based on these data are only for lookup,I ...
5
votes
2answers
143 views

Getting ApplicationName (sqlserver.client_app_name) to show up in an xevent

I am trying to examine some T-SQL with extended events like I used to with SQL profiler. I have the following event session: IF EXISTS (SELECT name FROM sys.dm_xe_sessions WHERE Name = 'PySoup ...
1
vote
1answer
79 views

SQL Server 2012: Give rights to read ddl but not modify?

What rights would I need to be give a user for them to be able to view all DDL code (such as stored procedure code) but not be able to edit any of it? The only possibility seems to be DDLadmin, but ...
1
vote
1answer
86 views

Why doesn't SQL Server rollback the identity_insert state?

I have a large script for setting up a new database that does lots of identity inserts on many tables; while I'm working on extending it I quite often have transient errors due to it being a work in ...
1
vote
1answer
61 views

What does a “Buffer cache hit ratio” of 9990 mean?

I got this query from a blog post: SELECT object_name, counter_name, cntr_value FROM sys.dm_os_performance_counters WHERE [object_name] LIKE '%Buffer Manager%' AND [counter_name] = 'Buffer cache hit ...
0
votes
0answers
21 views

SQL Server Mirroring with Certificates

I'm struggling with setting up mirroring with the following configuration: Server 1 running SQL Server Standard 2008 R2, Principal Server 2 running SQL Server Standard 2008 R2, Mirror Server 3 ...
0
votes
0answers
19 views

Add/remove tables in merge replication without full snapshot

I have a laboratory system that need to be installed in different collection stations, each with a independent database installation, but synchronizing some data among them, such as tests results, ...
2
votes
2answers
104 views

What's worse, too many entities or too many tables?

I just had a question about database design, I am in fairly early learning stages of this so bear with me. Suppose I have a parent table called "Projects" each "Project" Entity can have any number of ...
1
vote
0answers
88 views

SQL Agent After installation not able to start

SQL Server 2012 SQL Agent will not start after installation. Checked permissions, on surface configurations, all OK, have tried to run it as another account no Joy. The error i am receiving is the ...
0
votes
1answer
39 views

Order to restore system and user databases

We are going to move an sql instance to a new physical server (SQL SERVER 2008 r2). The answer to this question explains how Agent jobs and ssis-packages will be moved by restoring the master and ...
5
votes
2answers
72 views

Finding the query causing the missing index DMVs

How can I find the query causing the missing index DMVs suggesting to create a particular index? Thank you.
0
votes
2answers
60 views

SQL Server Express to SQL Server Standard upgrade?

The database size on our SQL Server Express database is around 10GB. I checked our database size and it said 38GB. Do I need to upgrade to SQL Server Standard edition? Is it expensive to upgrade? ...
0
votes
0answers
21 views

What is the appropriate value for DBCC CLEANTABLE batch size?

I have removed to NVARCHAR(MAX) columns from a table and what to calculated how exactly the table size was reduced. Usually, I am rebuilding the clustered indexes but the table has more then 1.6 ...
0
votes
1answer
35 views

How to become an administrator for SQL Server

Here is the situation: I Installed VS2013 That comes with SQL Server Express I am not able to create a DB from VS2013 thinking that it's because of user privilege issues, I Installed SQL Server ...
10
votes
2answers
125 views

SQL Server Index Update Deadlock

I have 2 queries which when run at the same time are causing a deadlock. Query 1 - update a column which is included in an index (index1): update table1 set column1 = value1 where id = @Id Takes ...
0
votes
1answer
50 views

dedicated SQL instance for SQL agent

Have an environment that has dozens of SQL instances all running SQL agent jobs for their own maintenance as well as other processes (etl, etc.) but considering a change to consolidate the ...
1
vote
3answers
69 views

Transaction log reported full but is not

Batch jobs error emails report: The transaction log for database 'WebDB' is full. No, it isn't. Its 90% free. The transaction log backups run normally. My hardware guy tells me the hardware is ...
1
vote
0answers
42 views

Failed to notify 'DBA Team' via email

I setup a test job to test out my failure notifications and now I'm getting the following stating it did not notify my operator via email. The strange thing is I ran the same exact setup script on ...
2
votes
0answers
36 views

SQL Server transaction log reported full when it isn't [duplicate]

The transaction log for database 'WebDB' is full. No, it isn't. Its 90% free. The transaction log backups run normally. My hardware guy tells me the hardware is running perfectly, with plenty of ...
1
vote
0answers
46 views

SQL Server transaction replication agent error

We are running transaction replication on SQL Server 2008 R2 SP3. Distribution agents are reporting : "Agent is retrying after an error. 3 retries attempted" every 10 minutes. Tried changing ...
1
vote
0answers
28 views

Replication / Bulk Update between Servers

I'm looking to update several tables between two servers daily to have a replica of the data available. My question is, what is the least resource heavy and most effective method to implement this? ...
-1
votes
0answers
22 views

Need urgent help for DataBase design decision [duplicate]

I am designing database for B2b market. Catalog: is Colletion of Product,size,prices,delivery date and other data. I need to design catalog on basis of three datasourceType .On The basis of ...
0
votes
0answers
34 views

RapidMiner Not Connecting To SQL Server Database Connection

I recently installed RapidMiner and tried connecting the application to my MS SQL database connection via the Manage Database Connections feature. I have followed video tutorials on integrating SQL ...
0
votes
1answer
37 views

How to get average according to last update time?

There is table - Item below, how can I get the average Value according to its 15 minute value from last record time? I am using SQL Server 2008. Table -- Item Table 15min_AVG
0
votes
0answers
17 views

Missing index recommendation for an already existing index [duplicate]

SQL Server missing index DMVs suggest to create an index which already exists. The existing one and the suggested one exactly overlap each other; they are single (same) column index with no included ...
0
votes
1answer
48 views

SQL Server CONTAINS ignores single quote before asterix [closed]

Let's say I have table NamesTable, which has text index on Name column DECLARE @String2 NVARCHAR(20) = '"SomeName''*"' SELECT * FROM NamesTable WHERE CONTAINS(Name, @String2) What does single quote ...
1
vote
1answer
50 views

Executed a Stored Procedure in the Production Server and the following warning message is shown [closed]

I executed a stored procedure on the production server; and though it shows that query has been successfully completed it doesn't allow me to close SQL Server Management Studio and the below warning ...
1
vote
0answers
47 views

Upgrade to SQL Server 2014 from 2008 R2

We are currently running SQL Server 2008 R2 and want to upgrade to 2014 but we need to leave some DBs at 2008 so we have decided to create a separate 2014 server and just migrate some DBs to it. Is ...
0
votes
0answers
24 views

Set up sql server db mirror specifying IP address for mirroring_partner_instance

Ok. I run: ALTER DATABASE DbName SET PARTNER = 'tcp://10.0.0.0:5022' Command completed succesfully Then run SELECT DB_NAME(database_id) AS 'DatabaseName', mirroring_partner_instance FROM ...
1
vote
0answers
50 views

Zero rows updated while archiving rows [closed]

I'm trying to archive rows from one schema to another on the same server using the approach outlined here: http://dba.stackexchange.com/a/31461 BEGIN TRAN BEGIN TRY INSERT INTO ...
1
vote
0answers
47 views

When will SQL Server automatically use a supporting indexed view?

I have the following expensive query that runs against our data warehouse: SELECT d.DateYear, COUNT_BIG(*) AS WidgetCount FROM Widgets AS w JOIN Dates AS d ON d.DateId = w.DateId WHERE ...
0
votes
0answers
31 views

Scheduled Job Succeeds, Does Nothing; Manual Job Succeeds, Performs Requirements

I have a job in SQL Server Agent (2012 Instance) that deletes rows from a table. When I manually run the job, it succeeds without issue and in reviewing the table, does exactly what I want it to do. ...
0
votes
0answers
50 views

Error: Package ‘Microsoft SQL Server Management Studio Package’ failed to load [closed]

I have SQL Server 2008 R2 64bit installed with SQL Server Management Studio (SSMS). I've been using SSMS for log time but recently when I try to open SSMS, I get the above error. I've tried all the ...
0
votes
3answers
98 views

Database design what are your thoughts

For years I have dinked with and now considering making it into a real project. I am thinking about developing a 'driver' of sorts that sits on top of RDMS( oracle, MSSQL, MySQL - others to follow). ...
0
votes
1answer
54 views

How to determine which statement is blocking an update in SQL Server

We have an UPDATE statement running in a large J2EE application that is getting blocked by some other statement. The update is using the primary key, so it should affect only one row. The isolation ...
1
vote
1answer
24 views

Clear missing index DMVs

How can I clear missing index DMVs such as dm_db_missing_index_group_stats, dm_db_missing_index_groups and dm_db_missing_index_details? I don't have an option to restart the server or taking it ...
3
votes
1answer
96 views

How to avoid Forced reboots using unattended upgrades to SQL Server 2014

Upgrading seven instances from SQL Server 2008R2 to 2014 via the ADMINISTRATOR command line using a configuration file. The upgrade runs fine but when I move on to upgrading the next instance I get ...
0
votes
0answers
30 views

SQL Server 2008 Linked Servers Consistently Dropping Connections

I have set up a Linked Server between 2 SQL Server 2008 R2 databases (both 10.50.1600). The linked server worked normally for several weeks until I received reports that users were not able to hit ...
1
vote
1answer
31 views

SSRS executionlog having rowcount 0

I'm reviewing some execution logs for long running queries in SSRS. A common thread I'm seeing is reports that seem to take a few hours to process, with a rowcount of 0. I'm using the following query ...
-2
votes
1answer
44 views

Find difference between two database and output them in a script sql [closed]

I had a SQL Server 2008 R2 database. I have dump it and made some mods in a copy. So, I have two databases: 1) the older version 2) the new version I need a script SQL to update the number 1) to ...
0
votes
1answer
48 views

SQL Server 2012 Enterprise: Copy Databases to New SQL Server, Same Domain, Users, Etc

Am having trouble with what seemingly should be an easy process. I'm a SQL Server n00b, so please be gentle and very explanatory with your answers. Currently, I have a SQL Server 2012 cluster ...
0
votes
1answer
68 views

Identity/Primary Key columns pattern for performance in SQL?

I was discussing about database layout/design with a friend and I got some questions about performance and best practices. I'm mainly a software programmer, so I may lack "common sense" regarding ...
-1
votes
2answers
52 views

What happens when play with constraints [closed]

I'm inserting data from one DB to one other on another instance by using the following method: Create insert into scripts from the source DB. TargetDB: DROP constraints, insert data and Create ...
1
vote
2answers
121 views

Programmatically determine whether a database was shut down cleanly or whether it required crash recovery

There are various ways to shut down the SQL Server service (I can think of at least: SHUTDOWN, SHUTDOWN WITH NOWAIT, stopping the service (including bugs), killing the process, power loss). An ...
2
votes
1answer
48 views

Listing expired SQL logins

For audit purposes, we need to list all SQL logins with their creation and expiration dates. Is there a way to script this for all of my SQL Servers, rather than performing the task manually through ...
1
vote
1answer
73 views

Powershell Output Help

I have wriiten the following SQL script to execute using powershell. cls foreach ($svr in get-content "demo.txt") { $con = ...