29,188 reputation
23789
bio website rusanu.com/articles
location Seattle, WA
age 42
visits member for 3 years, 6 months
seen 2 hours ago

1d
comment Why is there a collation conflict between system views
Should be safe, as long as you don't go cross-checking DBs (... from db1.sys... union from db2.sys...)
1d
answered Why is there a collation conflict between system views
Aug
18
comment How to escape '%' inside varchar @params for RAISERROR funcion in SQL Server 2012
Store %% in the database too, where the message comes from.
Aug
18
answered How to escape '%' inside varchar @params for RAISERROR funcion in SQL Server 2012
Aug
14
comment Why is it @@SERVERNAME but not @@DBNAME?
Path dependence
Aug
14
comment distributed queries are configured to run in single-threaded apartment mode
You don't need the full blown 64 bit Excel. As Mark mentioned, there is a JET redistributable AccessDatabaseEngine_x64.exe
Aug
14
comment What are the best ways to thrash SQL Server?
SQL Server Distributed Replay
Aug
13
comment A query that does a lot of reads, but plan is OK
post the STATISTICS IO output for the two runs.
Aug
13
answered Mirroring Database tables and views on SQL Server Express
Aug
13
comment Sch-M WAIT blocks Sch-S in SQL Server 2014 but not SQL Server 2008 R2?
You're using same service as initiator and target. The SEND blocks while checking the initiator queue. SEND would not block on the target queue, it would simply bounce and use sys.transmission_queue for delivery. If you separate the two (always a good idea) you wouldn't have the problem.
Aug
13
answered Shrink Transaction Log While Using AlwaysOn Availability Group
Aug
13
answered How to get a sense of how busy is the server
Aug
12
answered How to get service broker database queue status?
Aug
12
answered Is Information in sys.dm_db_index_usage_stats reliable
Aug
11
comment Slow compilation of a SQL statement
Read How to analyse SQL Server performance for how to collect wait times for an individual statement. Repro the problem while collecting the wait times then use the query from the same link to obtain the aggregate wait times for the statement. Post here the results.
Aug
7
comment How to do partition on a non clustered index column?
@BillAnton: no. I mean dev/ops cost, and not the last actual query runtime cost.
Aug
6
awarded  Enlightened
Aug
6
awarded  Nice Answer
Jul
31
revised Adding non-nullable NEWSEQUENTIALID() column to existing table
edited body
Jul
30
comment Adding non-nullable NEWSEQUENTIALID() column to existing table
@GreenstoneWalker the index builder does sort. Easily tested with a plan, eg. gist.github.com/rusanu/bd478cf99d472937375e <CreateIndex>...<Sort>.... But thanks for the vocabulary correction.