Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase 1234»»»

Disabling Indexes Expand / Collapse
Author
Message
Posted Thursday, September 9, 2010 9:32 PM


Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Today @ 7:46 AM
Points: 1,415, Visits: 1,831
Comments posted to this topic are about the item Disabling Indexes

Thanks & Regards,
Nakul Vachhrajani.
http://nakulvachhrajani.com
Be courteous. Drive responsibly.

Follow me on
Twitter: @sqltwins
Google Plus: +Nakul
Post #983550
Posted Thursday, September 9, 2010 10:47 PM
SSCrazy

SSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazy

Group: General Forum Members
Last Login: Monday, June 16, 2014 9:38 AM
Points: 2,163, Visits: 2,189
Nice question, thanks!
Post #983555
Posted Thursday, September 9, 2010 11:17 PM
UDP Broadcaster

UDP BroadcasterUDP BroadcasterUDP BroadcasterUDP BroadcasterUDP BroadcasterUDP BroadcasterUDP BroadcasterUDP Broadcaster

Group: General Forum Members
Last Login: Sunday, June 29, 2014 11:26 PM
Points: 1,481, Visits: 1,960
"ALTER INDEX PK_MyId ON MyTable DISABLE" at this line my brain stopped.

Nice question. Though i think it would have been better if i had stopped at the row above. Since if one didnt know that disabling the clustered index made it impossible to select from the table. You would have selected the 2 row answer anyway.
Post #983560
Posted Thursday, September 9, 2010 11:28 PM


Hall of Fame

Hall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of Fame

Group: General Forum Members
Last Login: Today @ 8:03 AM
Points: 3,928, Visits: 5,116
Good question.
shows the dangers of disabling indexes


____________________________________________
Space, the final frontier? not any more...
All limits henceforth are self-imposed.
“libera tute vulgaris ex”
Post #983562
Posted Friday, September 10, 2010 12:59 AM
Hall of Fame

Hall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of Fame

Group: General Forum Members
Last Login: Friday, May 9, 2014 12:47 AM
Points: 3,448, Visits: 4,407
The question would be more educational if it had no 'DROP CONSTRAINT' statement. In this case I would probably have answered wrong
Post #983572
Posted Friday, September 10, 2010 2:42 AM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Tuesday, August 26, 2014 5:18 AM
Points: 158, Visits: 51
i have checked the same on sql server 2005 on windows server 2003 but i am getting the error message
The query processor is unable to produce a plan because the index 'PK_MyId' on table or view 'MyTable' is disabled.
i think you should check it again.
Post #983602
Posted Friday, September 10, 2010 3:34 AM
SSCrazy

SSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazy

Group: General Forum Members
Last Login: Monday, June 30, 2014 2:51 AM
Points: 2,017, Visits: 369
nice one thanks...
Post #983618
Posted Friday, September 10, 2010 3:35 AM
SSCrazy

SSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazy

Group: General Forum Members
Last Login: Monday, June 30, 2014 2:51 AM
Points: 2,017, Visits: 369
This works on sql 2005... plz. check... you would have commented this line

ALTER TABLE MyTable DROP CONSTRAINT PK_MyId

mukeshkane (9/10/2010)
i have checked the same on sql server 2005 on windows server 2003 but i am getting the error message
The query processor is unable to produce a plan because the index 'PK_MyId' on table or view 'MyTable' is disabled.
i think you should check it again.
Post #983620
Posted Friday, September 10, 2010 3:39 AM


Old Hand

Old HandOld HandOld HandOld HandOld HandOld HandOld HandOld Hand

Group: General Forum Members
Last Login: Friday, August 1, 2014 8:28 AM
Points: 357, Visits: 910
Fascinating. Thanks
Post #983621
Posted Friday, September 10, 2010 5:25 AM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Tuesday, August 26, 2014 5:18 AM
Points: 158, Visits: 51
still getting the same error message
Post #983661
« Prev Topic | Next Topic »

Add to briefcase 1234»»»

Permissions Expand / Collapse