Reputation
32,457
Next tag badge:
982/400 score
80/80 answers
Badges
8 82 138
Newest
 Nice Answer
Impact
~1.0m people reached

Apr
13
answered SQL Server - Changing a column from NOT NULL to NULL - What's going on under the hood?
Apr
13
comment SQL Server - Changing a column from NOT NULL to NULL - What's going on under the hood?
RandyMinder - This is new syntax for 2014. Search for WITH ( ONLINE = ON | OFF) <as applies to altering a column> in the link from @ypercube.
Apr
13
comment SQL Server - Changing a column from NOT NULL to NULL - What's going on under the hood?
After testing with referencing the column in an NCI which consisted of 1731 leaf pages, 7 2nd level pages and a root page and altering to NULL caused 1731 logged entries for LOP_FORMAT_PAGE,LCX_INDEX_LEAF and 7 for LOP_FORMAT_PAGE, LCX_INDEX_INTERIOR so does look to be not metadata only after all. Maybe for the reasons @souplex suggests.
Apr
13
comment SQL Server - Changing a column from NOT NULL to NULL - What's going on under the hood?
Probably blocked waiting on a SCH-M lock. Unlike the opposite case pretty sure this is metadata only. You can check sys.dm_os_waiting_tasks whilst it is blocked.
Apr
13
awarded  Enlightened
Apr
13
awarded  Nice Answer
Apr
9
comment UPDATE() Function (Insert and Update Triggers)
I don't think this is relevant? Pretty sure they are asking about this msdn.microsoft.com/en-us/library/ms187326.aspx
Apr
7
comment Can statistics affect the query logic instead of performance?
Yes this is entirely possible as discussed in this Connect Item connect.microsoft.com/SQLServer/feedback/details/537419/…
Apr
7
comment Unexpected Implicit conversion in a procedure
@Stackoverflowuser - No need to hurry.
Apr
6
answered Shorthand for on primary key?
Apr
6
comment Estimated versus actual query plan with function calls
@usr - This one here? 3 months? That must be a record turn around for a new feature request!
Apr
6
comment Shorthand for on primary key?
No, there is no such syntax.
Apr
6
comment SQL queries failing, Memory not releasing
"queries begin to fail" in what way?
Apr
6
comment Estimated versus actual query plan with function calls
@usr - Maybe because the actual cached plan that is selected can vary dependant on the actual number of rows as described here? technet.microsoft.com/en-us/library/…
Apr
6
comment SQL Server index causing incorrect behavior on cursors
@max you're responsible for avoiding the issue yourself with dynamic cursors. See this section by Ken Henderson books.google.co.uk/…
Apr
5
comment Inner Join and Right Join same query
This returns 1 and 2 SQL Fiddle
Apr
5
revised Inner Join and Right Join same query
added 25 characters in body
Apr
5
comment SQL Server : Index Seek with very high Scan Count
Please show the exact query, the table definitions, number of rows in both tables and the execution plan.
Apr
5
comment SQL Server : Index Seek with very high Scan Count
stackoverflow.com/a/21778788/73226
Apr
3
comment Guid vs INT - Which is better as a primary key?
Makes sense!...