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

learn more… | top users | synonyms (2)

1
vote
0answers
7 views

Breaking up large transaction - worth it?

I'm in charge of monitoring the performance of an industrial chemistry process. Every hour, a process gathers 50 million rows from various subsystems and feed into the central database. The whole ...
1
vote
0answers
17 views

Exporting to excel from OPENROWSET with cell formatting

I am trying to generate a report from SSMS to Excel, using OpenRowSet. All is working fine, still I have to export a specific column with a barcode font. I already have the column calculated from ...
0
votes
1answer
25 views

How to list the permissions on User-Defined Table Types?

I am using some user-defined table types. They are very useful. you can see information about them by running this simple script: SELECT o.* from sys.table_types o I have a procedure that shows me ...
1
vote
1answer
52 views

SQL Server 2012 Setup error Attempted to perform an unauthorized operation

Below is the detailed error message. I Can't proceed with installation for the last one week? I've given full rights to registry keys that are associated to SQL Server but nothing has worked out. For ...
1
vote
1answer
22 views

Problem Getting Simple Replication to Work in SQL Server 2008/2012

I can't resolve a problem with replication. The publisher/distribution side seems just fine, but when I subscribe and view in the replication monitor I always get this error: "a required privilege is ...
3
votes
1answer
79 views

dbcc memorystatus - buffer pool target on VM higher than max memory

I'm doing some digging into potential memory/configuration problems on a sql server 2012 SP2. I stumbled upon something that seems a bit strange in the performance counters as well as the dbcc ...
2
votes
1answer
16 views

How to get the spatial index in CREATE TO script?

Is it possible to get the spatial index using the create to script using SQL Server 2012? When I write out a table using SCRIPT TABLE AS > CREATE TO in Microsoft SQL Server Management Studio 2012, I ...
1
vote
1answer
28 views

one table for all blob with a one to one table for metadata which link to one or many tables?

I'm going to start by saying that I'm not a DBA but i got that role in my current project so I'm doing my best. The application must be able to store files(attachments, official documents, etc) The ...
1
vote
1answer
18 views

SQL Server 2012 Business Intelligence licensing

I have Microsoft SQL Server 2012 Entreprise Edition license, What are the tools needed to work on SSIS/SSAS/SSRS? Since BIDS was replaced with SSDT on the 2012 version, does it mean I will need to ...
1
vote
2answers
57 views

PAGEIOLATCH_SH and LCK_M_IX wait type

I'm seeking for a resolution into wait types I observe on one of my servers. I've been keeping wait statistics for a long time and can positively say that the top two are PAGEIOLATCH_SH and LCK_M_IX ...
0
votes
2answers
26 views

SQL Server De-duplication Trigger

I have a table that contains columns of Country, City, Location, Description. Due to the size of the description field it's not possible to bind the four fields into a composite key to prevent ...
4
votes
0answers
19 views

AlwaysOn Availability Group error after Windows Update in environment without a failover cluster

Our SQL Server service was down this morning which brought down some of our websites. When I went to check the Windows Event Viewer I saw the following errors: Script level upgrade for database ...
3
votes
1answer
188 views

Verify if user has read access to a table

I'm developing an ETL, whose extract step must read data from a table. There are times that my user's access to that table is revoked. So, to avoid the ETL failing, before reading the table I must ...
0
votes
1answer
53 views

Job showing the running sign but not currently running

I have a script to get the currently running jobs: -- get the running jobs --marcelo miorelli -- 10-dec-2013 SELECT sj.name ,DATEDIFF(SECOND,aj.start_execution_date,GetDate()) AS Seconds FROM ...
0
votes
0answers
55 views

Query execute slowly when changed compatibility Level of my database

I use SQL Server 2014 and have a database with compatibility level 110 (SQL Server 2012). also I have a stored procedure on it that execute about 10 second. When I change compatibility level of my ...
1
vote
1answer
44 views

01/01/1753 date is corrupt in Excel after export from SSRS

The date 01/01/1753 appears fine in the SSRS 208R2 report preview, but when the report is exported to Excel 2010, it appears as ########### and the value in the cell is -53689. All other dates come ...
2
votes
0answers
48 views

How to UPDATE/DELETE/INSERT with Microsoft.ACE.OLEDB.12.0 as Linked Server in SQL Server 2012?

I need to update an Access 2003 database from SQL Server 2012 with the Microsoft.ACE.OLEDB.12.0 provider. As an administrator, everything works great. I can do Select, Insert, Update and Delete ...
1
vote
2answers
90 views

Using sp_BlitzIndex - Diagnosed as “Index Hoarder: Addicted to nulls” [duplicate]

Context: MS SQL Server 2012 In using Kendra Little's awesome tool, sp_BlitzIndex, a number of tables were diagnosed as "Index Hoarder: Addicted to nulls". I'm not looking for a debate over NULLs and ...
0
votes
2answers
47 views

Is it normal for tempdb to not give up disk space when it releases things?

So my tempdb is getting huge. Like 200+ GB. USE tempdb GO EXEC sp_spaceused database_name database_size unallocated space tempdb 211668.88 MB 206803.45 MB It's using a SIMPLE ...
2
votes
1answer
78 views

How to get CPU usage by database for particular instance?

I have found the following queries to detect the CPU usage by database, but they are showing different results: WITH DB_CPU_Stats AS ( SELECT DatabaseID, DB_Name(DatabaseID) AS [DatabaseName], ...
0
votes
1answer
38 views

Procedure permission issues with a SQL state query

We have a login/user with DBO to a single database, and now we're adding a query that's providing some basic monitoring information requiring permissions extending somewhat to the sysadmin side. ...
3
votes
0answers
39 views

AlwaysON : Log_Send_Queue_Size is increasing but the log_send_rate keeps decreasing?

Question Why, despite the increasingly log_send_queue_size for these two databases, did the log_send_rate keep decreasing? There were no bandwidth issues on the network at this time, and no other ...
0
votes
1answer
41 views

SQL Server 2012 install hangs during the RunRemoteDiscoveryActiom

I've tried multiple times to install SQL Server 2012 on a 2-node cluster. I've tried multiple different media. Each time it hangs shortly after the initial validation check. The detail log for the ...
0
votes
1answer
47 views

SQL Server 2012: stored procedures permissions

Is it possible to control permissions on a single stored procedure level in SQL Server 2012? It seems that SQL Server Manager doesn't expose such functionality via GUI. Can somebody advice me how to ...
0
votes
0answers
27 views

How to test a SQL Server 2012 Cryptographic Provider

One of the nodes in my SQL Server 2012 availability group has been having problems with an external cryptographic provider. It's current separate from the rest of the availability group and can't be ...
0
votes
4answers
86 views

Restoring master database

I am trying to restore master database, when I set the server to single mode user I am unable to connect I get the error below. Sqlcmd: Error: Microsoft SQL Server Native Client 11.0 : Login ...
1
vote
1answer
74 views

Find out who ran a query using transaction log backups

We have a SQL Server 2012 Enterprise database running in Full Recovery Model with transaction log backups running every minute. A query was run last night which means we need to recover data from a ...
0
votes
0answers
30 views

How best to index large table with many index keys

In our datawarehouse load, we bring data in the following manner. 1. from source to stage 2. stage to a consolidation layer 3. from consolidation layer to operational data store (ODS) ...
0
votes
0answers
29 views

Restoring a SQL Server 2012 database in high availability

I have a database which is in always-on high availability mode synchronized with another database on a different instance. How can I restore from a .bak file into the primary database using T-SQL? ...
0
votes
1answer
28 views

Unable to call sp_start_job from website only

I have an agent job that I'm trying to use to kick off an SSIS package via a web page. I have configured my web site running in an application pool as user X. When I invoke sp_start_job as use X ...
0
votes
1answer
203 views

Does SQL Server require SSLv3?

We have a Windows 2008 R2 server running SQL 2012 Express RTM (11.0.2100.60). All three protocols (shared memory, named pipes, TCP/IP) are enabled for the server and both 32-bit and 64-bit clients. ...
3
votes
2answers
79 views

Trigger firing when it shouldn't

I have the following trigger: CREATE TRIGGER SalaryCannotDecrease ON Employees AFTER UPDATE AS IF EXISTS ( SELECT * FROM inserted, deleted WHERE inserted.Salary ...
1
vote
0answers
19 views

Adding a distributor for availability groups

According to this MSDN article, I need to add a distributor. http://msdn.microsoft.com/en-us/library/hh710046(v=sql.110).aspx I'm confused by this particular statement: The distributor should not be ...
-2
votes
1answer
26 views

Foreign Key Error [closed]

Getting this error on my database and I don't know how to fix it: Msg 547, Level 16, State 0, Line 1 The INSERT statement conflicted with the FOREIGN KEY constraint ...
0
votes
2answers
54 views

SQL Server 2012 Very Slow to Consume Memory

I have a bit of a conundrum. I recently upgraded a ~20gb database from Window Server 2008 R2 || SQL Server 2008 R2 to Window Server 2012 || SQL Server 2012. The previous server had 32gb of memory, ...
0
votes
1answer
38 views

Stored proc getting ANSI_NULLS and ANSI_WARNINGS error when executed by application

I have a stored procedure that is getting the following error when executed via an application : Heterogeneous queries require the ANSI_NULLS and ANSI_WARNINGS options to be set for the ...
0
votes
1answer
24 views

ODBC connection for testing Availability Group Listener

I am having difficulty verifying my Availability Group Listener configuration. I would like to create an ODBC connection which points to the listener. When I configure the system DSN and try to test ...
0
votes
1answer
23 views

non clustered index on same table but the order is different?

I have one table it has 5 columns like col1...col5 . i need to create non clustered index on col2,col3,col4. I did .. then my boss is asking me create one more non clustered index on col4,col3,col2 ...
0
votes
0answers
19 views

sys.sp_audit_write Procedure not available

I am trying to execute the audit write procedure but it can't be found. I have looked in master for it in the system procedures list and confirmed it isn't there. Does anyone know why this might be? I ...
0
votes
1answer
51 views

Linked Server from SQL Server to SSAS not working - what is missing?

I have a SQL Server 2012 Standard edition sp1 that has ssas also installed. From this server I create a linked server to a ssas server called BIREPLON1, but when I try to access it, I get the error ...
0
votes
1answer
52 views

Is there a way to minimally log insert under Always on?

I have a primary database in FULL recovery mode which is part of Always On group. Is there a way to minimally log insert operation under FULL recovery model? I have a process that is executed each ...
0
votes
1answer
28 views

SQL Server 2012 how to create new schema from existing database selecting only subset of database objects?

I'm looking for a way to create new schema from existing database selecting only subset of database objects. I.e. I want to have some "database representation" which only includes subset of tables ...
0
votes
1answer
64 views

How SQL Server agent calculates next run date for a job

I am developing a system for scheduling task & I am following Microsoft SQL agent approach to schedule task. I have replicated sysschedules table for capturing users scheduling occurrences and ...
1
vote
2answers
210 views

SQL Server Grant execute on all stored procedures without ddl permissions

I have some users in my database. They are member of db_datareader. They now also need to have execute permissions on stored procedures. I was just wondering what would happen if one of the stored ...
0
votes
1answer
70 views

A transaction log grows unexpectedly [duplicate]

I am trying to understand what process is making my transaction log file to grow. For example, currently it is 120 GB and only 5-10 MB of it are in use. Before: FULL recovery mode a backup of the ...
0
votes
2answers
55 views

Can't create table in database with db_owner role (SQL Server 2012)

I have database in SQL Server 2012 SP2 Enterprise. I created new SQL Login and mapped to X database with db_owner role. Now I can't create table on this database. When I run simple create table script ...
1
vote
1answer
13 views

Can I minimize maintenance of duplicated Windows + SQL Auth logins?

In our environment, SQL authentication is the norm, but Windows auth is possible when users are using RDP. As a result, each physical user has two logical logins for each instance and two logical ...
0
votes
1answer
20 views

Select Ingredients of a product based on unit type

I have three tables UnitType,NutritionMaster, NutritionInProduct UnitTypeID UnitName 1 100ml contains 2 250ml contains NutritionID Name Description 1 Energy NULL 2 ...
0
votes
0answers
44 views

How to fix deadlock caused by “X” locks on same resource?

I have the following <resource-list>: <resource-list> <keylock hobtid="72058301601677312" dbid="7" objectname="myDatabase.dbo.TableOne" indexname="PK_TableOne" id="lock2c336fb380" ...
0
votes
1answer
45 views

SQL Server Developer Edition Downgrading to Older Developer Edition

I have seen answers for questions regarding downgrading from different editions (e.g. - Enterprise to Standard), but is anyone familiar with downgrade policies for SQL Server Developer editions to ...