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)

12
votes
0answers
283 views

Is sys.stats_columns incorrect?

Let's say I have a table Foo with columns ID1, ID2 and a composite primary key defined over ID2, ID1. (I'm currently working with a System Center product that has several tables defined this way with ...
12
votes
0answers
338 views

What is the cause of this problem with CONVERT()?

Consider the following two statements: PRINT CONVERT(NUMERIC(38, 0), 0x0100000001, 0); PRINT CONVERT(NUMERIC(38, 0), 0x0100010001, 0); Both statements return -1; isn't that incorrect since the ...
8
votes
0answers
86 views

SQL Server 2014 schema changes in 24/7 multi user environment

We have SQL Server 2014 Enterprise installed to run a database which should be available 24/7. Our database is huge enough (200gb +). Also we have a lot of services that hits our database every minute ...
7
votes
0answers
143 views

Avoiding “Row by row” fetch method when dealing with source LOB columns

I have a legacy PostgreSQL database source (ODBC) that I'm attempting to migrate to new SQL Server schema using SSIS. I'm getting a warning saying: 'Row by Row' fetch method is enforced because ...
6
votes
0answers
122 views

How to set MSDN in order to open on a certain version of Microsoft SQL Server?

In a network, there are certain different installed versions of Microsoft SQL Server, starting with 2005, 2008 and 2008 R2. Is there a specific option of MSDN that can fix the opening of new pages on ...
6
votes
0answers
209 views

Timestamp-based index

I have a big database (200GB+) that contains some log info. And I want to speed up SELECT queries and stored procedures. I have a table with a GeneratedOnUtc datetime column, and have a non-clustered ...
6
votes
0answers
2k views

There is insufficient system memory in resource pool 'internal' to run this query

One of our production servers is reporting an error in the log Error: 701, Severity: 17, State: 123. There is insufficient system memory in resource pool 'internal' to run this query. I ...
6
votes
0answers
510 views

Trace Flag 1222 Not Working?

I have a customer site with two similarly configured 2008r2 SQL Servers "A" and "C". On both servers the trace flags 1204 and 1222 are enabled and DBCC tracestatus shows the following on both ...
6
votes
0answers
238 views

Best way to get time zone key name from SQL Server

Below is what I pieced together but I wanted to see what other ways are available. SET NOCOUNT ON; GO DECLARE @tz VARCHAR(50) EXEC [master].[dbo].[xp_regread] 'HKEY_LOCAL_MACHINE' ...
5
votes
0answers
114 views

Identical query slower when searching for `T` rather than `F`

I have a legacy database that uses char(1) with 'T' and 'F' for boolean values. The only values in the field are T and F, of the following queries, the first is instantaneous, the second takes 30 ...
5
votes
0answers
83 views

Instant File Initialization on Shared drive

I asked something similar to this before, but previously I had asked about moving backups to a shared location. This time I am curious, if I want to restore a DB on a shared drive, do I need to enable ...
5
votes
0answers
65 views

stats_column_id and index_column_id do not update with physical order of clustered index is changed

Unless I'm misunderstanding the purpose of the column, the following code indicates that a change of the structure of the clustered index does not change the ordinal position (stats_column_id)of the ...
5
votes
0answers
164 views

Frequent, “random” SQL Server connection timeouts

For the last few days our clients have been suffering intermittent connection timeouts to our database server. Multiple Ajax calls on the same page which connect to the server multiple times are ...
5
votes
0answers
437 views

Did the Change Tracking internals change from SQL Server 2008 to 2012?

In trouble shooting an issue with synchronizing disconnected devices with a central database server, we are experiencing a problem after upgrading to SQL Server 2012 on the server. It appears that the ...
5
votes
0answers
226 views

How to properly troubleshoot Merge Replication False Conflicts

We have SQL Server 2008 R2 Merge Replication setup. Lately I started getting conflicts for some tables, and when I check the conflict viewer, I can see that the winner & the loser column values ...
5
votes
0answers
376 views

What does duration measurement in sql server actually measure?

What precisely does the query duration measure when conducting a profiler trace? I have a stored procedure which performs data access (SELECT), and it is taking an average of around 30 seconds to ...
4
votes
0answers
18 views

Move content between filestream containers

I have a server running SQL2012 with Multiple Filestream containers on a single table. I need to split one of the existing filestream containers into two parts by creating a new filestream container ...
4
votes
0answers
61 views

Which to trust?

We are troubleshooting a long-running issue with a vendor. Their software has a tendency to freeze up and stop working once or twice a week causing major disruptions to our operation. They have been ...
4
votes
0answers
78 views

Why is my Azure SQL Server so slow?

We currently have a VM that is very underpowered and are proposing to move to an Azure VM with better specs. The problem is, the Azure VM is much slower than the original VM even though it is of a ...
4
votes
0answers
69 views

When does SQL Server acquire locks?

The list of isolation levels in SQL Server found here states that write locks acquired within a transaction are retained until the end of the transaction. However it doesn't mention anything about ...
4
votes
0answers
101 views

Why could a SQL Server table grow far quicker than the data to it?

I've got an audit table in SQL Server 2008 R2 that has the following structure: CREATE TABLE [AuditInstance]( [oid] [int] NOT NULL, [AuditTransactionOID] [int] NULL, [pid] [int] NOT NULL, ...
4
votes
0answers
1k views

How to troubleshoot “client driver has sent multiple requests while the session is in single-user mode”

I'm working with a developer who is struggling to stop the following error: The server will drop the connection, because the client driver has sent multiple requests while the session is in ...
4
votes
0answers
73 views

sql server spatial index performance

I have a table with around 2 million records in it. I created a spatial index, using the defaults other than the bounding box. I've been noticing that some queries are extremely fast, and some are ...
4
votes
0answers
2k views

High CPU in SQL Server supporting SharePoint databases while running FAST search crawl

I have a a SQL Server 2012 (SP1) #cu5 (X64) instance used as SharePoint 2010 back end and for the most part use only 10 - 30% CPU but there is a high CPU usage when running FAST search crawl(both ...
4
votes
0answers
497 views

SQL Server Internal Memory Pressure

I am trying to identify the cause of internal memory pressure. From what I have learned, Resource Monitor Ring Buffer returns an indicator for internal pressure. For example by using this query, ...
4
votes
0answers
191 views

Conflict handling, SQL Server 2008 R2 Peer to Peer

I have a Peer to Peer replication topology set up between two SQL Server 2008 R2 servers. I was doing some testing on fault tolerance and conflict handling. I have conflict detection enabled, and ...
4
votes
0answers
132 views

How to Audit for Access with Cross Database Ownership Chaining

I've just joined the data team of a new company and we have a large SQL Server environment (100+ instances) and cross database ownership chaining is on by what I gather is a necessity. I'm looking for ...
3
votes
0answers
77 views

Leap second in Database system (Postgresql and SQL Server)

This night will be longer because of leap second: https://en.wikipedia.org/wiki/Leap_second My impact will be minimal in my case, I don't even know if I will recive some weird data like 20150630 ...
3
votes
0answers
50 views

How to uniquely identify SQL instance

I need to find a way how to identify SQL Instance no matter what changes were done to SQL Server and\or Windows Server where it is running, because we're collecting remotely information about ...
3
votes
0answers
39 views

In Sql Server, is there a way to check if a selected group of rows are locked or not?

We are attempting to update/delete a large number of records in a multi-billion row table. Since this is a popular table, there is a lot of activity in different sections of this table. Any large ...
3
votes
0answers
52 views

MS SQL Server IO read increase appear randomly

The number of read (IOPS) in my MS SQL Server database increased randomly even during the night (low activities) from 0.3 MB/SEC (normal) to 25-30 MB/SEC. After like 30 minutes, it's capped to 6 ...
3
votes
0answers
62 views

Is it possible to get seek based parallel plan for distinct/group by?

An example from this question shows that SQL Server will choose a full index scan to solve a query like this: select distinct [typeName] from [types] Where [typeName] has a non-clustered, ...
3
votes
0answers
145 views

Interpreting sys.dm_os_sys_memory

I try to figure out a way(using only TSQL) to determine if and how much the PAGEFILE (I will capitalize this term if I refer to the windows page file from now on) is used (like pagefileusage% ...
3
votes
0answers
56 views

Take action from extended event?

I've seen it mentioned a few times that you can configure an event session to take an action when an event fires. Does anyone have any information on how to do this? I know that you can use the ...
3
votes
0answers
91 views

Is it possible to have different authentication mode for SQL Server Database Engine and corresponding SQL Server instance?

I have installed the x64 SQL Server 2008 R2 Express with default settings and run MBSA 2.3 Microsoft analizer (using default settings too). Tried on clean Windows 8 installation (not 8.1) and Windows ...
3
votes
0answers
85 views

Why is my SQL Server query behaving differently on UPDATE than on SELECT?

I've written a SQL Server query that updates records to have a sequential number after partitioning on a field. When I run it as a SELECT statement, everything looks great: DECLARE @RunDetailID INT = ...
3
votes
0answers
68 views

Change Tracking across several Tables

I'm looking into providing DB level change tracking within my system. I need to be able to track changes at an entity level, rather than just individual tables. Right now, we have triggers on each of ...
3
votes
0answers
92 views

Find out why SQL Server released memory

I have a SQL Server 2008 R2 used for sharepoint and ssrs. The SQL Server hosts two instances. For a few minutes both instances were timing out, not responding. CPU slowly rose to 100%, 30% from ...
3
votes
0answers
60 views

Can SQL Server use a spatial index and another index at the same time and be efficient?

Let's say we have a table that contains two terrain datasets defined by TerrainModelID like below: CREATE TABLE [dbo].[DigitalTerrain]( [DigitalTerrainID] [uniqueidentifier] NOT NULL, ...
3
votes
0answers
63 views

Why is the lease locked for a some full sql backups to Azure Blob using Ola Hallengren backup scripts?

I'm using SQL Server 2012 and working on backing up to Azure Blob using Ola Hallengren backup scripts. Some backups are lease locked (ex. model) while others are not (ex. msdb). It's inconsistent, it ...
3
votes
0answers
93 views

ASSIGN value for cmd in sysprocesses? What does it mean?

We're seeing some strange blocking behaviour in a production (SQL Server 2008 R2) system that we're investigating, and it seems to have one consistent and novel element: in the sysprocesses table, the ...
3
votes
0answers
4k views

how to resolve intermittent SQL backup issue?

We have this issue on aprox 100-300 SQL machines each month and it's never re-occuring. If you re-run the backup it will complete. The problem exists in both win2k8 and win2k12 machines. Backup ...
3
votes
0answers
1k views

How do I give file system access to SQL Server's SQLSERVERAGENT virtual account?

I'm trying to grant the NT Service\SQLSERVERAGENT Windows account file system access, based on the marked answer in this question. I believe it's a virtual service account, and it does not show up in ...
3
votes
0answers
359 views

DTUTIL to package store

I am trying to deploy a package to a project in my SSIS catalog and am using the following command: dtutil /FILE C:\Changes\ReceivedEDI.dtsx /DestS MARSQL12 /COPY ...
3
votes
0answers
837 views

Once more about SQL Server virtual accounts

Let me reboot my question on SQL Server virtual accounts permissions The (same) MSDN article on the same version 2012 of SQL Server "Configure Windows Service Accounts and Permissions" states: ...
3
votes
0answers
147 views

SQL Server 2012 Resource Governor and memory used by CLR

In SQL 2012 memory used by CLR is now part of what is controlled by "MAX Server Memory" a) Does Resource Governor in SQL 2012 Enterprise (MAX_MEMORY_PERCENT for resource pool) governs CLR memory? ...
3
votes
0answers
209 views

How can I search values, considering occurences, on more than one term in SQL Server CE?

I have a rather complex SQL query, that I actually received help from this SE site to come up with parts of. This query is designed to take a search term and search all relevant values in a database ...
3
votes
0answers
2k views

Severity 016 Backup virtual device fail

My backup on one of my servers is failing once a week. This is the alert I'm getting: DESCRIPTION: BackupVirtualDeviceFile::PrepareToFreeze: failure on backup device ...
3
votes
0answers
178 views

custom population of full text index

Is there any way to populate a full text search index without storing the backing information in the database? I don't mean using remote-blob-storage or FILESTREAM types. The backing information is a ...
3
votes
0answers
166 views

merge replication too big

I have multiple handhelds which sync their data via merge replication. from time to time, new core data is imported on the server-database. for some reasons I keep the old data in the databse and set ...