Costing and Statistics, continued…

I started off tonight playing with the new page compression feature.  So far I like it.  I haven’t found something yet about which I want to post (which is code for “I’m still looking for the seams ;)”), but I have some other things you can try to learn a few things about how the […]

Statistics, Damned Lies, and Statistics – What is Statman?

One of the areas I managed in SQL Server had to do with the code that automatically builds statistics and uses them during query optimization to come up with a good plan.  Today I’m going to talk a bit about how statistics are built and how this works with parallelism and partitioning. First things first.  […]

Slow Outlook 2007 on Vista (x64)

I’ve returned from a small trip and I will be preparing my next SQL post soon. I’ve been struggling with slow POP3 sync behavior on my Outlook 2007/Vista 64 box, and I finally found a hammer to beat it back into submission. The problem – I sync manually, and when I do the application becomes […]

How to write non-JOIN WHERE clauses

Based on my previous post describing the differences between ANSI-89 and ANSI-92+ join syntaxes and recommendations, I had a follow-up question in a comment which was (paraphrased) What do I do with non-join WHERE clauses – how should I write those? Example: SELECT p.FirstName + ‘ works in ‘ + d.DepartmentName AS ‘Who Works Where’ […]

ON vs. WHERE – where should you put join conditions?

I had a request from a reader that I’ll answer today about when to do joins in the ON clause and when to do them in the WHERE clause.  For example: SELECT * FROM A, B WHERE A.a = B.b vs. SELECT * FROM A INNER JOIN B ON (A.a = B.b) The short answer […]

Local-Global Aggregation

I don’t know about you, but groupby is one of my favorite operators.  There are a TON of interesting optimizations that a QP considers when you start adding group by into queries, especially when you have joins and then a group by.  TPC-H benchmark wars among the large database vendors are won and lost on […]

Hunting for SQL 2008 SPARSE Column Easter Eggs

So I was playing today with the sparse column implementation in the latest SQL 2008 CTP, and I was specifically looking to see how this thing would work with the query processor.  I wanted to know how much information is exposed for the QP to make smart decisions when this functionality is used in complex […]

1753, datetime, and you

So now that I have the latest CTP working again on my main machine, it’s far less troublesome to go research things and post what I find.  Tonight I’ll talk a little about datetime vs. date, as dates are on my mind for whatever reason. So the “old” SQL Server datetime type only goes back […]

SQL 2008 CTP Installation Problems – Largely Fixed

Well, I was able to get things to finally install using the information from my previous post and using a named instance (different from the default instance I used previously).  So, while I’d still like to track down the keys that define an installation instance with enough detail to remove them, I think I’ve gotten […]

Progress on the SQL 2008 CTP6 Installation Problems

You may recall my previous posts on my trouble with SQL 2008 CTP6.  I’ve made some progress on fixing my machine that I thought I’d share with you.  I now get past the following error: D:\temp\sqlctp6\servers>setupThe following error occurred:MsiGetProductInfo failed to retrieve ProductVersion for package with Product Code = ‘{00E75F61-A126-4CE1-90B8-42295052F1AC}’. Error code: 1605. I useded […]