Solved

SQL Server 2005 defragmenting index primary key

Posted on 2012-03-19
3
286 Views
Last Modified: 2012-03-19
Can defragmenting, rebuilding or reorganizing a SQL Server 2005 index which is used as an identity specification primary key field for a table change the values in the field? (Destroying queries based on the primary key values)
0
Comment
Question by:machine_run
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 69

Accepted Solution

by:
Scott Pletcher earned 400 total points
ID: 37739545
No.  None of those activities will change the actual values in any column.  

More specifically for identity, once an identity value has been assigned, it will never change.
0
 
LVL 40

Assisted Solution

by:lcohan
lcohan earned 100 total points
ID: 37739643
"Destroying queries based on the primary key values" - only thing may be gone is(are) old cached query plans but this is a good not a bad thing. If you have some "sticky" cache you may need iisreset if a update statistics and sp_recompile on that table do not help.
0
 
LVL 1

Author Closing Comment

by:machine_run
ID: 37739684
THANKS!!!!!!!!
0

Featured Post

Why You Need a DevOps Toolchain

IT needs to deliver services with more agility and velocity. IT must roll out application features and innovations faster to keep up with customer demands, which is where a DevOps toolchain steps in. View the infographic to see why you need a DevOps toolchain.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

So every once in a while at work I am asked to export data from one table and insert it into another on a different server.  I hate doing this.  There's so many different tables and data types.  Some column data needs quoted and some doesn't.  What …
In this article I will describe the Copy Database Wizard method as one possible migration process and I will add the extra tasks needed for an upgrade when and where is applied so it will cover all.
In a recent question (https://www.experts-exchange.com/questions/29004105/Run-AutoHotkey-script-directly-from-Notepad.html) here at Experts Exchange, a member asked how to run an AutoHotkey script (.AHK) directly from Notepad++ (aka NPP). This video…

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question