This tag is for SQL Server 2012, major build version 11.00.xxxx.

learn more… | top users | synonyms (2)

1
vote
1answer
15 views

What does it mean? ORA-06502: PL/SQL: numeric or value error: character string buffer too small

Q 1: Whenever an Oracle SP wants to return error code/message, it fails returning below exeption: OLE DB provider "OraOLEDB.Oracle" for linked server "ORASRV" returned message "ORA-06502: PL/SQL: ...
4
votes
1answer
65 views

How to display rows that are missing from aggregations?

I create a view to display ValueRange like this: ... ValueRange=case when Value1>60 and Value1<=65 then '60-65' when Value1>65 and Value1<=70 then '65-70' ...
0
votes
2answers
25 views

Management Studio System.OutOfMemoryException

I'm using Microsoft SQL Server 2012 and trying to run a simple query against it within Management Studio. I'm getting the following error: An error occurred while executing batch. Error message ...
0
votes
1answer
38 views

Simplest way to edit single entry in XML column?

As I understand MS SQL Server Management Studio doesn't allow directly editing/replacing entries in XML columns via GUI (copy/paste doesn't work etc.). What is the easiest option to replace a single ...
1
vote
2answers
164 views

How to get Identity Column to jump ahead (by say 1000) on SQL Server 2012

I am using SQL Server 2012 and I would like to keep my pre-existing data but to cause the ID (identity) column to skip by 2000 rows. Why is this happening? I have a scenario where I may have ...
0
votes
0answers
31 views

sql query cant group this table's data according to first column

WITH t2 AS (SELECT Tarih , [0-20000] = COUNT(CASE WHEN Yük= 20000 and Yük= 21000 and Yük= 22000 and Yük= 23000 and Yük= 24000 and Yük= 25000 and Yük= 26000 and Yük= 27000 and Yük= 28000 and Yük= ...
0
votes
0answers
21 views

SQL query to return columns per value in value range?

I have a table like this: Date Value1 Value2 2009-12-30 23334 93 2009-12-31 21989 97 2010-01-01 18638 62 2010-01-02 ...
1
vote
2answers
34 views

Changing compatibility level of database causes performance improvement of stored procedure

We have a Web Application in a Windows Server 2012 Datacenter (IIS 8), running under .NET Framework 4.0, which connects to another Windows Server 2012 Datacenter with SQL Server 2012. My Database has ...
0
votes
1answer
38 views

Why do my backup policies fail when a database's guest user is disabled?

I'm attempting to implement Policy Based Management on a SQL Server 2012 instance also acting as a Central Management Server using the Enterprise Policy Management Framework. The job running the ...
1
vote
0answers
21 views

Prevent SQL Server failback after cluster aware updating

We have SQL Server 2012 in a two-node cluster with Windows Server 2012 (node and disk majority). Neither of the nodes are marked as preferred owner and the "Prevent Failback" option is selected. ...
0
votes
1answer
17 views

SQL query to return a column per value in value range?

I have a table like this: Date Value 2010-01-01 18638,5416666667 2010-01-02 19666,0416666667 2010-01-03 19527,75 2010-01-04 23111,875 2010-01-05 23893,5 ...
0
votes
1answer
19 views

Installation of SQL Server 2014 and SQL Server 2012 on the same system

I have a system with a SQL Server 2012 Developer edition installed. Can I install SQL Server 2014 (6 months trial) and SQL Server 2012 on the same system? I do not want to overwrite the pre-existing ...
1
vote
1answer
42 views

Fix transaction log file after database update

I have a databases that are regularly (monthly) updated. An update includes a lot of new or changed T-SQP procedures, functions, indexes creation, etc. A database X has transaction log file with the ...
0
votes
0answers
30 views

Configuring multiple listeners on SQL Server 2012 through High Availability

We have configured two SQL servers on Azure and they are in HA. There are about 10 databases and we wanted to have two critical ones on one dedicated HA group. The listener worked fine until we ...
0
votes
0answers
24 views

KPI behavior (Calculate member)

I have create the following tendency (IIF([Measures].[Age]=TRUE,1,0)+ IIF([Measures].[Idle]=TRUE,1,0)+ IIF([Measures].[Labor]=TRUE,1,0))/3 My issue is that in excel if I use this (or the kpi) the ...
1
vote
0answers
57 views

SQL select top X rows having sum limit

I am using SQL Server 2012, I have a table with a format such as : MyOrders : ID -> PK int Cost -> float Category -> int I want to get the following : Input : category (lets say 2). ...
1
vote
0answers
18 views

What are recommended (working) permissions for a user to view all SQL Agent jobs

A new user (associated with an existing login) is created in msdb and assigned membership: use [msdb]; create user [TheUser] for login [AnExistingLogin]; alter role [SQLAgentUserRole] add member ...
3
votes
1answer
74 views

Does sp_indexoption cause index rebuilds?

I want to switch AllowRowLocks=ON on a number of indexes. Some of those indexes are on large tables, and I don't really want to rebuild or reorganize the index. It is not clear from the MSDN article ...
0
votes
0answers
28 views

Replication overview

My boss wants me to elaborate a comprehensive report about synchronisation/replication. I know that replication can be done with the DBMS (we are using SQL Server 2012), but he wants something manual ...
1
vote
0answers
28 views

How to add SQL Server in networks list?

After changing my PC name and workgroup, I am no longer able to connect to SQL Server. Currently in my servers list I have only Home & localhost. Anybody know how to add server to networks list? ...
1
vote
0answers
25 views

Error when trying to deploy SSIS package

I am trying to deploy my 2012 SSIS project to the Integration Services catalog on the SSIS server (also 2012). I am getting the error below. I checked that there is plenty of space in SSISDB and ...
2
votes
0answers
43 views

AlwaysOn FCI + HA Setup Question

I am planning to create FCI + HA solution in the same datacenter, but running into some problems. I'd really appreciate if someone can provide some guidance. Here is the current configuration (All ...
0
votes
2answers
80 views

Stored Procedure null parameter within where clause

I want to use a parameter within where clause only if it's value is provided by strongly typed dataset, this is what I am trying at the moment, I get right results when I provide parameter3 and no ...
0
votes
0answers
28 views

SSIS Package truncation and possible data loss (error code: 0xC020901C)

Good morning all, It's been 2 days now trying to figure out how to solve this issue, still no answer. Maybe you can help me out. Here is the thing. I have created an SSIS package to import data from ...
2
votes
0answers
18 views

Change Data Capture not running when Mirror is Suspended

We have 2 SQL 2012 SP2 Enterprise servers that have some mirrored databases. One of these databases also has CDC enabled on a number of tables so that we can run some business logic when there are ...
0
votes
1answer
18 views

SSIS foreach loop xlsx files

Hello I see similar questions has been ask before but I am having a bit of trouble with this issue, this is using excel 2013 data files and sql server 2012. I have a foreach loop container This for ...
3
votes
1answer
61 views

FlushCache messages appearing in log at specific times

We've been having a lot of database performance issues lately, and I've been trying to see if I can figure out why. We don't have a DBA (I'm a software developer) so I'm sort of just winging it, and ...
2
votes
1answer
39 views

Failover Cluster Diagnostic Logs

I know there must be a simple answer to this question, but I cannot find it anywhere. Our SQL 2012 FCI have SQLDIAG .XEL files in their MSSQL\LOG folder. In some instances, these files are often ...
1
vote
1answer
34 views

Linked Server and MSDTC on cluster

I'm trying to set up a linked server between two instances we have on our network. I've done this many times before without an issue, but this time I repeatedly get the following error: OLE DB ...
0
votes
0answers
19 views

Is it best practice to include partition keys within foreign keys when referencing partitioned tables?

The large tables in our database are partitioned by an id in order to separate data and speed up IO. The table of the data is partitioned by the partition key, but the primary key is only on an ...
1
vote
0answers
29 views

Does the order of columns in a non-clustered ColumnStore index matter? [duplicate]

I'm reading about creating a non-clustered ColumnStore index. I noticed that when I modify an already created non-clustered ColumnStore in SQL Server Management Studio I have an option to change the ...
0
votes
0answers
23 views

SQL SERVER 2012 Express - Can't change Thesaurus Location

I have a requirement for an application to change the location where SQL SERVER looks for the Global Thesaurus file. According to the official documentation: "You can change the location and names ...
2
votes
0answers
28 views

How to add a missing database to an AlwaysOn Availability Group [duplicate]

Setup: Microsoft SQL Server 2012, and we have 3 production servers(prod1, prod2, prod3) with AlwaysOn. We recently added a new database and the new database was added to our Availability Group(named ...
0
votes
2answers
42 views

SQL Server 2012 Can't log in with machine account

We're migrating an IIS/SQL Server site from 2008 to 2012, and I'm having a problem with authentication. We use Windows Authentication to authenticate as DOMAIN\COMPUTER$, but this isn't working, ...
0
votes
0answers
22 views

Is it possible for a SELECT-only stored procedure to deadlock on itself?

Environment is Microsoft SQL Server 2012. Is it possible for a stored procedure consisting exclusively of SELECT statements to deadlock on itself? That is the report I am getting from a vendor for ...
2
votes
1answer
28 views

Obtaining the next partition number

For a partitioned table, how do I determine via T-SQL what is the next partition number that will be used? For example, the switch-in today went into partition number 50. I want to build the new ...
4
votes
2answers
78 views

Cannot remove SQL Server 2012

I was in the process of installing SQL Server 2012 x64 Express Management Studio and encountered one heck of an issue. I was most of the way through the installation process when my computer locked ...
0
votes
1answer
42 views

Change code editor variable highlighting colour

Within the SSMS Code Editor (for SQL Server 2012) I have this code written within the editor, that has a Dark theme applied. When you click on a variable, SSMS highlights all the other occurrences of ...
1
vote
1answer
25 views

SSAS : An error occurred when instantiating a metadata object

Aside from installing SSAS, I have no experience using it. Our developers are saying that it is no longer possible to create a new aggregation, whatever the cube. The error occurs when hitting ...
0
votes
1answer
37 views

How to get SQL Server filetable path locator for subfolder by its literal path

I have a filetable which have several subtables. For example FileTable ->subtable1 ->->subtable1.1 ->->subtable1.2 ->subtable2 ->subtable3 etc How to get SQL Server ...
0
votes
1answer
41 views

Shrink Transaction Log While Using AlwaysOn Availability Group

We are using AlwaysOn Availability Group feature of SQL Server 2012. Regular full database backups and transaction log backups are done every day on the secondary database. I have read here doing the ...
0
votes
1answer
43 views

Can anyone recommend a beginner DBA course in London [closed]

My organisation is in need of a SQL Server DBA and as the companies only "SQL Guy" my boss has suggested me to take SQL Server DBA course. My general T-SQL knowledge is fairly good, I can write ...
2
votes
2answers
59 views

SQL Server: Apply Custom Server Role afterwards for already existing databases

I needed a custom SQL Server role which has readonly access to all databases, regardless of whether a database is existing or is newly created. The role is not a problem. The problem is that the ...
0
votes
1answer
36 views

Select rows other than first selected row in a table

My table looks like id ledgerID Amount Debit or credit TransactionType -------------------------------------------------------------- 1 1 500 dr ...
1
vote
1answer
39 views

Backup/restore of a database that has a filestream

I have a SQL DB to which I have recently added Filestream data. Now we have a daily backup/restore to a QA server, and since I added the Filestream data, this has started failing. So I modified the ...
0
votes
0answers
12 views

PowerShell 'get-ClusterQuorum' output is not showing 'QuorumType' column

PowerShell cmdlet 'get-ClusterQuorum' output is not showing "QuorumType" column. Has anybody seen this before? Thanks
1
vote
2answers
46 views

What happens when Core Cluster Group is failed over to another node? Will it take the whole cluster down? Single point of failure?

"Cluster group" fail-over will cause cluster go offline. Really? Single point of failure? Am I missing something? What happens when Core Cluster resources (Cluster Group) are failed over from one node ...
0
votes
2answers
65 views

How secure is a linked server in SQL Server

I am in a situation in which I should doubt everyone (even my developer team and database admin) so I want to Log all the logons made to my server. I have two SQL Servers, say A and B. I want to log ...
0
votes
1answer
69 views

Script that alters all stored procedure on the database

I have a database with thousands of stored procedures and I need to alter hundreds of them. In order to do it faster I thought of a way to write a script that runs over all stored procedures and adds ...
0
votes
2answers
55 views

Order by for 2 row result causes 800% performance hit

The following query, run against a table of about 6 mil rows takes 25 seconds. When I remove the final order by, it runs in 3 seconds. There are no indexes on the table (it's an intermediate SSIS ETL ...