This Tag is for SQL Server 2008 R2, major build version 10.50.xxxx

learn more… | top users | synonyms (2)

7
votes
1answer
707 views

SQL Server not using available memory

SQL Server 2008 R2 Standard Edition (64-bit) on Windows 2008R2 Enterprise Server has over 300 GB of memory but total memory use in control panel never goes over 86 GB Have SQL configured to use ...
1
vote
2answers
8k views

What is the most effective way to compress and store a SQL Server backup? [closed]

I've been doing some testing of different methods for compressing and storing SQL Server backups (using SQL Server 2008 R2 Enterprise edition), and I'm wondering what the most effective compression ...
5
votes
1answer
588 views

How can a fill factor of 0 or 100 be the same?

As of my understanding, Fill factor of 80 implies that 20 percentage of each leaf-level page will be empty to enable future growth. I can't correlate how fill factor of 0 and 100 can be the same! Am I ...
6
votes
0answers
385 views

SQL Server Sproc calls from IBM Cast Iron orchestration with XML payload fail

I'm hoping that someone on this forum may have experience with an IBM appliance, Cast Iron (Websphere), and how it interacts with SQL Server. I know very little about the Cast Iron appliance, and its ...
3
votes
1answer
650 views

Why does Log Shipping .TRN file copy just stop

I apologize in advance for a long post but I have had it up to here with this error of having to delete LS configuration and starting it over for any DB thats got this error. I have LS setup on 3 ...
2
votes
1answer
2k views

Invalid object name 'master.dbo.MSreplication_options' when restoring DB

I've tried Googling for an answer to this but have got nowhere. I have one SQL Server instance whose replication is set up to be a publisher and a distributor of FooDatabase. I have a second ...
1
vote
0answers
350 views

Can SQL Server 2008R2 SSIS packages access SQL Server 2012 databases with driver updates only?

We have two products running on SQL Server that we will be upgrading to SQL Server 2012 on a staggered schedule. Product B uses SSIS packages (using ODBC drivers) to extract data from Product A's ...
1
vote
1answer
543 views

Sneaky rollback in SQL Server 2008 R2

Is it possible for an entire set of committed transactions to be rolled back in SQL Server 2008 R2 without any notification or logging anywhere? We had a set of data apparently get rolled back this ...
4
votes
3answers
3k views

How to undo every change made to a database in a controlled environment?

I'm doing system testing of a product, and several tests are severely changing the data of a demo database. The data is quite complex to create queries which will undo the changes done by the tests; ...
5
votes
3answers
6k views

Can a database's files be copied while a database is online?

I'm working on setting up a development copy of a production database on SQL Server 2008 R2 SP1. The live database is getting lightly used by two developers for read only queries currently, but the ...
3
votes
3answers
9k views

Difference between Full backup and Copy-only full backup

I saw in this link that full backup does not truncate the log. So what is the difference between full backup and copy-only full backup? For the log backup there is copy-only backup which prevent the ...
3
votes
5answers
561 views

Extract data to another computer

I have SQL Server 2008 R2 Express edition, and I want to export the data in that database to another computer so I can import it again in that computer. How please? What I have tried Right-click ...
2
votes
1answer
253 views

Import issue with Replication

When I import some data from excel file to a table that is part of a merge replication, the data is imported successfully to the table, but those new records are not synced to subscribers that belong ...
2
votes
1answer
44 views

Removing superfluous tables with a synchronization?

I'm using SQL Server 2008 r2's replication functionality to update my subscriber database through a transactional pull subscription. When I mark it for reinitialization, it does fix the schema and ...
2
votes
1answer
92 views

ALLOW_SNAPSHOT_ISOLATION Duration

I would like to enable ALLOW_SNAPSHOT_ISOLATION on a production database that has ~400 million total records. I understand that 14 bytes will need to be added to each record. If I set ...
1
vote
2answers
2k views

Active Directory group permissions not being applied to user [duplicate]

I have an odd situation. An Active Directory group was recently created for the sole purpose of being a securable in SQL Server. I created a login based on the AD group, a user based on the login, and ...
5
votes
1answer
1k views

Partitioning / indexing an extremely large table

I'm working on indexing and partitioning a single data warehouse table that weighs in around 500 GB. The table is a heap, has over a hundred TEXT columns, and the TEXT_IN_ROW option is enabled. I ...
4
votes
2answers
1k views

Default trace enabled but not active

When I query the configuration of the default trace, it shows enabled: exec sp_configure 'default trace enabled'; --> name minimum maximum config_value run_value default ...
8
votes
3answers
2k views

Dealing with identity ranges for transactional replication

I've noticed that when you set up a transactional replication, SQL Server will set identity range management to manual. What this means is that in my subscription database, when I try to insert a new ...
5
votes
2answers
286 views

One table used in two databases

I have a common product table in db1 and db2. I want to make it one table because it has one inventory (stock of products). What is the best solution to share product table among two different ...
1
vote
1answer
435 views

Migrate database from SQL Server 2005 to SQL Server 2008 R2

DBAs... please be gentle with me, I'm a 'greenhorn' SQL Server DBA, pressed into service because my company's DBA had resigned and we haven't found his replacement, yet. First, my situation: I'm ...
1
vote
1answer
383 views

How to edit publication's generation_leveling_threshold configuration value

I dont know where I put this code: update sysmergepublications set [generation_leveling_threshold] = 0 I only need do it. But I need edited any funcion of agent.
3
votes
1answer
6k views

Login failed for user Error: 18456 State: 10

In one of my vb.net applications I am getting the error Login failed for user 'user'. But the user has full permission (sysadmin). Also this error happens intermittently. Error log has the following: ...
-1
votes
1answer
130 views

Query performance in SQL Server [closed]

What factors should I check when I compare the performance of a query? I saw many articles stating about IO cost, subtree cost (by using Execution plans), statistics such as CPU time, elapsed time ...
0
votes
1answer
467 views

Compatibility level for published database and transactional replication

I am running a database on compatibility level 80 because the application using it does not yet support a higher level. It is my understanding that transactional replication on SQL Server 2005 and ...
4
votes
1answer
2k views

Error using an Execute SQL script to load a date variable in SSIS

I'm trying to populate a variable using an Execute SQL task in SSIS. The table structure is as follows: CREATE TABLE BuildControl (Id INT NOT NULL Identity, BuildDate Date, Country char(2), ...
13
votes
2answers
531 views

Vendor Wants to Run MSDB job every 5 minutes for Business Application

We have a 3rd party vendor trying to integrate 2 different applications where both DBs reside on our SQL Server instance with 150+ other DBs, and they want to create a MSDB job to "synch" the 2 ...
0
votes
1answer
2k views

SQL replication Agent permission

Error messages: The schema script 'teste2_2.sch' could not be propagated to the subscriber. (Source: MSSQL_REPL, Error number: MSSQL_REPL-2147201001) The process could not read file ...
4
votes
3answers
3k views

Running Total which Resets when Customer changes (keeping existing RowNumbers)- attempt included

I have a table where the RowNumber is of essence. It has a range of clients, and a running total for that client - which resets every time the Client changes. e.g. client rownr amount runtotal ...
-3
votes
3answers
3k views

Shrink Database using query [closed]

I have deleted tons of records from my database and now i want to shrink the database. So please give me script which shrinks the database
1
vote
3answers
274 views

Unused Indexes - Consider Primary Key Constraint Supporting Indexes?

I have given a task to find out the unused indexes in my production environment. I'm using a DMV to find the unused indexes should i include the Primary key Clustered Indexes on it? If a Primary key ...
1
vote
0answers
296 views

Transactional Replication times-out with Database Snapshot on subscription

I have a VLDB that is being replicated using transnational replication. The performance has been terrible, and the process frequently times out. After much investigation, including Service Packs and ...
1
vote
1answer
109 views

When importing raw files for internal conversion, should I use a secondary database or just isolate them within the database?

When importing raw files for internal conversion, should I use a secondary database or just isolate them within the database? I've got between 1.25 and 2GB of CSV files to be imported (and already ...
13
votes
1answer
6k views

How to write a query which finds all circular references when a table references itself?

I have the following schema (names changed), which I cannot change: CREATE TABLE MyTable ( Id INT NOT NULL PRIMARY KEY, ParentId INT NOT NULL ); ALTER TABLE MyTable ADD FOREIGN KEY ...
-1
votes
2answers
11k views

Query to search for a substring in xml

I use below query to search for a substring in whole xml(including node name and node value) SELECT * FROM tablename WHERE ( Charindex('abc',CAST([xmlcolumn] AS VARCHAR(MAX)))>0 ) I want an ...
1
vote
3answers
3k views

copy only tables with data from one database to another database [closed]

I have two database , dbOne(version - 10.50.1600 - locate in office server ) and dbTwo(version - 10.0.1600 - locate in my local server) . I want to copy dbOne's tables with data to dbTwo . Is there ...
7
votes
0answers
271 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 ...
0
votes
1answer
409 views

xml queries with exist and contains giving unexpected results

I have a query as shown below. DECLARE @tbl TABLE ( id INT, col XML ) INSERT INTO @tbl VALUES (1,'<Root> <Row> <User>xyz</User> ...
7
votes
2answers
553 views

Seek predicate not using all available columns

I have a strange query compilation issue which is hard to reproduce. It only happens under high load and cannot be easily repeated. There is a table T with columns A,B,C,D. There is a non-unique ...
1
vote
0answers
458 views

Search for string in xml column

I am using sql server 2008 r2 express. I have a table with column name 'xmlmycolumn' which is of datatype xml. I want to search for string in that whole xml. So to do this i am casting column as ...
0
votes
1answer
2k views

Permissions on sys.syslogins

I've got the following scenario: ( loggend in on SQL-Server with full admin-privileges ) Creating LogIn, User, Role and associate them. IF NOT EXISTS( SELECT "name" FROM "master"."dbo"."syslogins" ...
22
votes
2answers
21k views

What is the actual behavior of compatibility level 80?

Could somebody provide me with a better insight about the compatibility mode feature? It is behaving different than I expected. As far as I understand compatibility modes, it is about the ...
1
vote
2answers
2k views

How do I interpret the log when I run DBCC TRACEON (3502, 3504, 3605, -1)

I have been using DBCC Traceon (3502, 3504, 3605, -1) because it was recommended in a blog for discovering performance issues related to I/O. I'm running MS SQL Server 2008 R2 SP1 Results in my SQL ...
13
votes
1answer
18k views

SIMPLE or FULL recovery model for databases?

When should I use the full recovery model and when should I use the simple recovery model for databases? I always used the full recovery model because it is the default, but today i encountered this ...
0
votes
1answer
66 views

Give access to view or table?

I want to give an external user (new login) read access to part of the data model from my Database. The user will copy the data model and content from my Database, and then integrate that into their ...
16
votes
6answers
3k views

Trying to find the last time that a value has changed

I have a table that has an ID, a value, and a date. There are many IDs, Values, and dates in this table. Records are inserted into this table periodically. The ID will always stay the same but ...
3
votes
3answers
4k views

Nonclustered index is faster than clustered index?

Both tables have same structure and 19972 rows in each table. for practicing indexing, i created both tables having same structure and created clustered index on persontb(BusinessEntityID) and ...
3
votes
1answer
2k views

How to take partitions or filegroups out of service

I'm an experienced SQL Server DBA but new to partitioning, and I have a couple of questions. Using SQL Server 2008 R2 Enterprise Edition. I've inherited a large customer metrics database that grows ...
8
votes
1answer
704 views

How to make trigger code execute only for a specific application?

I was wondering if it is possible to enable a trigger just for my current application and not for any sql executed against the table. The situation: There are two applications working on the same ...
1
vote
0answers
18 views

How to take partitions or filegroups out of service [migration] [duplicate]

I'm an experienced SQL Server DBA but new to partitioning, and a had a couple of questions. Using SQL Server 2008 R2 Enterprise Edition. I've inherited a large customer metrics database that grows by ...