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

learn more… | top users | synonyms (2)

1
vote
1answer
276 views

RBS and Fail Over Cluster with SQL Server 2012

I am trying to install one SQL Server 2012 cluster with two nodes. I will also be enabling Remote Blob Storage (RBS) on server so I was wondering if I need to take something in account while ...
1
vote
0answers
120 views

Automatic Version increment on Data-Tier Applications

In the project settings of a database project I can set the version number form my data-tier application, however setting this manually is a bit inefficient. I would like to automatically increment ...
0
votes
3answers
2k views

Connecting to SQL Server instance through C# [closed]

I made a program, using c# and sql server with sql authentication. It works properly in my device, but after making the program setup file .exe extension using Innosetup, I cannot connect to my ...
5
votes
2answers
7k views

SQL Server not using all CPU cores/threads

After upgrading our SQL Server's hardware, we noticed in the Windows Task Manager that the SQL instance is only using half of the threads available to it: . The server has the following hardware ...
1
vote
2answers
1k views

SQL Server: Additional cpus slow down batch

I'm running SQL Server 2012 in Windows 2008R2 in a virtualized environment. I've observed the following under both VMware Workstation 9 and Hyper-V 2012R1 and I don't know how to address it. I've ...
2
votes
1answer
144 views

How do I access the full text of an error in SSIS GUI?

I have an Excel task which is providing error text through the GUI, but I don't know how to access the error task without the GUI and the error disappears if I move the cursor from the X I have the ...
1
vote
2answers
1k views

What is best way to storing geo coordinates related to planned route?

Here is my scenario: Application "A" produces lat and long points that correspond to planned route. Depending on route distance it could have several thousands of points. I know of Geography and ...
0
votes
0answers
181 views

Cannot set ArithAbort to Off on SQL Server

I have 2 SQL 2012 servers. The settings are exactly the same, but on one I can set ARITHABORT to Off but no matter how I try I can't do the same on the second server. The only difference I could find ...
1
vote
1answer
632 views

Troubleshooting Mirroring Configuration

I am configuring database mirroring on SQL Server 2012. After configuration I am getting the following error when attempting to start the mirroring session: tcp server cannot be reached or does ...
2
votes
2answers
1k views

Partitioning a Table Referenced by a Foreign Key

I have one table: CREATE TABLE [dbo].[entry] ( [ID] [bigint] IDENTITY(1,1) NOT NULL, [EntryDate] [datetime] NOT NULL, [createddate] [datetime] NOT NULL, CONSTRAINT [PK_Entry_ID] ...
1
vote
1answer
317 views

SQL Server 2012 SQL Log “the log file is not using Unicode format”:

On only one server of many, the SQL log is blank and shows a message "the log file is not using Unicode Format" when viewed via SSMS. The log is in the right location as specified in the service ...
2
votes
1answer
121 views

Query does not use index when selecting all records [closed]

This is my first time handling a large database, and I was wondering why the two queries below are different in terms of execution plan. I have setup an index on a specific table: CREATE ...
0
votes
1answer
3k views

Uncommitable T-SQL transaction after trigger applied to table

Good morning, I have written a Trigger on a table that should evaluate the entered values (Length, width and Height) and based on those entered values, should update a column (Type) in the same record ...
1
vote
1answer
2k views

Intellisense in SSMS 2012 not working for 2008 server

I did most of the solutions provided here. I know about enabling IntelliSense clearing the cache connecting to a server >= SQL Server 2008 using the latest SQL Server Service Pack and it works ...
1
vote
1answer
317 views

SSMS “New Query” Behavior

On my desktop and on most other instances of Sql Server 2008 R2 and 2012, the default behavior when you right click on a database in the solution explorer of SSMS and choose "New Query" is a new query ...
5
votes
4answers
942 views

Create a secondary read-only copy of DB in a different server

We have users that query our prod database (mostly ODBC through MS-Access) to create some customs reports. We want to copy our data to a second server (replicate / log shipping / ???) so the load on ...
1
vote
1answer
704 views

Imitate 'dynamic' columns in SQL Server

We have a central SQL Server 2012 database. There is a single table [tbl_Users] that stores all kinds of information pertinent to an employee, for example, UserID CustomerID FirstName Surname ...
4
votes
2answers
1k views

Restore Database SQL Server 2012

I'm a newbie when it comes to SQL Server, it would be helpful if someone could point me in the right direction. We have a database file that is called main-db.bak. This is the database file that we ...
2
votes
3answers
3k views

Check if SQL Agent job is being executed manually

I have a stored procedure that performs database backups. Because I'm looking at Availability Groups within SQL Server 2012 I want to utilise the *sys.fn_hadr_backup_is_preferred_replica* function ...
12
votes
2answers
5k views

Does a re-index update statistics?

I've been doing the MS10775A course this past week and one question that came up that the trainer couldn't answer reliably is: Does a re-index update the statistics? We found discussions online ...
0
votes
2answers
249 views

Access denied when disabling agent job, despite SqlAgentOperator membership

I am attempting to disable a SQL agent job from an account which a member of the SqlAgentOperator role (but not sysadmin) The doco says this should be possible 3 SQLAgentOperatorRole members can ...
2
votes
1answer
141 views

Transaction log autogrowth duration

I am using event notifications to capture data and log file autogrowth events for all databases on my servers. I'm using the data to for analysis of database storage configuration. In looking at the ...
4
votes
2answers
1k views

SQL Server tail log backup fails where it shouldn't

I am trying to set up a demo of backing up the tail of the log in case of disk failure, but it doesn't work as expected. The setup: Set AdventureWorks backup model to "Full", create a full, a ...
3
votes
0answers
274 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 ...
0
votes
1answer
2k views

SQL Server 2012 Reporting Services: “Unable to connect to the remote server”

I am trying to install SQL Server 2012 Reporting Services on Windows Server 2008, but all the web interface says after adding the feature and confirming all the default settings in Reporting Services ...
1
vote
1answer
1k views

How to setup SSL in SQL Server 2012 with own certificate?

Environment: Windows 7 Professional x64 in a domain, running SQL Server 2012. I have local admin rights, so messing up the system is easy. My SQL Server instances are SQLEXPRESS and MSSQLSERVER. FQDN ...
0
votes
1answer
1k views

What is the best practices to backup and restore full and partial database with SQL Server 2012 and C#?

How can I do the following with C#: Completely backup an existing database. Partially backup an existing database. Completely restore an existing database from a backup file. Partially restore an ...
6
votes
1answer
124 views

Is there a way to implement a cross-database task on SQL Server 2012 with the Availability Groups feature?

We use SQL Server 2012 and its new Availability Groups (AG) feature. There is a task for moving old data of some tables from one database to another database. Both databases are included into ...
4
votes
2answers
1k views

Comparing binary 0x and 0x00 turns out to be equal on SQL Server

It seems that SQL Server considers 0x and 0x00 equal values: SELECT CASE WHEN 0x = 0x00 THEN 1 ELSE 0 END This outputs 1. How can I get true binary bit-for-bit comparison behavior? Also, what are ...
3
votes
1answer
52 views

How is ORDER BY logically Processed

Take this example: SELECT SalesOrderID, CustomerID, SalesPersonID, OrderDate FROM Sales.SalesOrderHeader ORDER BY OrderDate, SalesOrderID DESC OFFSET 0 ROWS FETCH NEXT ...
1
vote
2answers
2k views

How to make SSMS upper case keywords

I recently started using Management Studio 2012. When using MySQL Workbench, a handy feature was that I could stay all in lower case and any reserved word (like SELECT, INSERT) would convert to upper ...
1
vote
0answers
59 views

SQL Server 2008 - a License question [closed]

We're planning to upgrade our environment from SQL 2008 to 2012. In one of our servers we have 2 instances of SQL 2008 Standard. It is a VM that has 4 CPU cores allocated to it. When we calculate the ...
3
votes
1answer
206 views

Optimizing complex join predicates [closed]

Table Definitions CREATE TABLE [dbo].[Pin_Mtg] ( [MtgId] bigint NULL, [CntyCd] char(5) NOT NULL, [BatchDt] int NOT NULL, [BatchSeq] int NOT NULL, [MtgSeq] tinyint NOT NULL, ...
1
vote
1answer
3k views

AWE memory usage growing with SQL Server 2012

I've got a problem with my SQL Server 2012 installation on my Windows 2008 R2 x64 box. (heads up: I have no idea what I'm talking about...I'm in over my head, since I have no real DBA ...
1
vote
1answer
4k views

Create two columns from one, based on two different WHERE clauses

SELECT TOP 1000 [Value] FROM [OnlineQnres].[dbo].[tmp_DataSets] WHERE [VariableID] in ('1') UNION ALL SELECT TOP 1000 [Value] FROM [OnlineQnres].[dbo].[tmp_oDataSets] WHERE ...
2
votes
2answers
1k views

SQL Server 2012 Availability Group issue

I need some assistance and some bandages for shooting myself in the foot. This is a DEV environment but I need to bring it up. I am using SQL Server 2012 Enterprise on Windows 2008 R2. Somehow our ...
1
vote
1answer
461 views

Advice needed for Querying DateTimeOffset data by end users

We are building an Operational Data Store (ODS). The data is coming from our production databases which are located in the United States and Asia. The data in our production databases store date/time ...
3
votes
1answer
2k views

How to get SQL Server 2012 to use the invariant culture in format()?

This has now been posted to Connect: The invariant culture identifier is rejected by the FORMAT() function in SQL Server 2012. I'm trying to get the built-in format() function in SQL Server ...
3
votes
2answers
2k views

SQL Server 2012 High Availability on VMware virtualization

We're going to host a large SQL Server 2012 under a VMware virtualization and we need it to be highly available. These are the three options I found supported, but couldn't find a lot of info and ...
1
vote
0answers
348 views

Ghost Cleanup process has high CPU usage in SQL Server 2012 SP1

Has anyone encountered this? We are using SQL Server 2012 Enterprise Edition with SP1. During a time of low/no activity, I noticed the Ghost Cleanup process is utilizing CPU at a very high rate, ...
6
votes
1answer
281 views

Why does my SQL Server show more than half a million active tasks?

select task_state,count(*) from sys.dm_os_tasks group by task_state I ran the above statement on a SQL Server instance, and found it had about 633,000 records. task_state -------------- ...
1
vote
0answers
291 views

DBCC Physical only giving Connection failure

I have a SQL server 2012 Ent DB. The hosting company is trying to setup new backup solution using Symantec Backup Exec. They have come back and said our database is corrupt because they get these ...
0
votes
4answers
4k views

How do I delete only related records in a multi-key MERGE in SQL Server?

Suppose you have something like this: Source table (variable): Values ( LeftId INT NOT NULL, RightId INT NOT NULL, CustomValue varchar(100) NULL ) Target table: Mapping ( LeftId INT NOT ...
3
votes
1answer
113 views

Conversions between any data type and the binary data types are not guaranteed to be the same between versions of SQL Server

I just found that on the SQL Server 2012 MSDN documentation for binary and varbinary types, they mention the following at the end of the article: Conversions between any data type and the binary ...
1
vote
3answers
937 views

Replication fails because of a non-existent foreign key

I have been trying to get a previously working replication to start working. I have tried many settings, but I can't seem to make it work. Here is the scenario. I dropped all the FK constraints ...
2
votes
2answers
4k views

Possible to run multiple Reporting Services (SSRS) instances on different machines with databases on same machine?

With SQL Server 2012, can SSRS instances be setup on two different machines, with both instances using the same machine for their SQL Server databases? Machine 1 SQL Server 2012 Database Server ...
0
votes
1answer
457 views

Full-text Search XML Properties

I'm trying to determine whether I can retrieve a property (attribute) value from an xml blob stored in a FILESTREAM-enabled column using Full-text search. Here is a sample where message is a ...
3
votes
4answers
3k views

SQL Server Min Server Memory

using SQL 2008 R2 with SP2 with a server with 64 GB of RAM. I have set max server memory to 58GB considering SQL Server is limited to only database engine related service only. I have a question ...
1
vote
0answers
394 views

Merge Replication Update Statement Timeout

I work for a company that provides web based data collection. Currently we have a SQL Server 2012 server as the publisher for 2 subscribers (planning on expanding up to 5+ subscribers), both SQL 2012 ...
3
votes
3answers
635 views

Simple XML .query SELECT statement times out on 1 SQL SERVER instance

I dropped and recreated a stored procedure on a DB on a SQL Server 2012 instance (SERVER1/INSTANCE1), after which the sproc started hanging on a line. Using profiler I have reduced a recreateable ...