Thoughts On A State of the Chapter Statement (and Doing More)
This is a follow up to a thought I voiced on Twitter last week – the value of a once a...
2014-11-18
562 reads
This is a follow up to a thought I voiced on Twitter last week – the value of a once a...
2014-11-18
562 reads
After wrapping up my part of SQLSaturday Orlando this year I’ve been thinking on what if anything we might do...
2014-11-17
751 reads
Based on limited but practical experience I believe chapters typically work hardest to find speakers and sponsors, the latter being...
2014-11-13
562 reads
Looking for a reason to show up at the 2015 PASS Summit on Monday, or just want something fun to...
2014-11-12
677 reads
I missed the Summit this year, but tried to follow along remotely via Twitter, PASSTV, and the blog posts I...
2014-11-07
931 reads
Each year for the past few years the PASS Board of Directors has conducted a Q&A session with members at...
2014-11-06
968 reads
Due to a minor health issue I’ve decided to – for once – be conservative and cancel the trip this year. I’ve...
2014-10-31
1,270 reads
One of my original goals was to be more reporter than editorial writer, but I’ve found that the editorial part...
2014-10-31 (first published: 2014-10-23)
5,630 reads
SQLSaturday Tampa is the first SQLSaturday in Florida for 2015, scheduled for February 28th, 2015. The event is held at...
2014-10-29
1,256 reads
Ran into a minor issue while installing SCOM. The wizard wants to create two databases. The first requires a minimum...
2014-10-16
692 reads
How can you achieve good enough without compromising the process/product? In the world of...
By Patrick
One of my customers recently wanted to rename each of the SQL audit files...
The post The pros and cons of self-service BI: What every industry leader should...
Comments posted to this topic are about the item What's New for the Microsoft...
Comments posted to this topic are about the item Using Outer Joins
I have this data in a SQL Server 2019 database:
Customer table CustomerID CustomerName 1 Steve 2 Andy 3 Brian 4 Allen 5 Devin 6 Sally OrderHeader table OrderID CustomerID OrderDate 1 1 2024-02-01 2 1 2024-03-01 3 3 2024-04-01 4 4 2024-05-01 6 4 2024-05-01 7 3 2024-06-07 8 2 2024-04-07I want a list of all customers and their order counts for a period of time, including zero orders. If I run this query, how many rows are returned?
SELECT c.CustomerName, COUNT(oh.OrderID) FROM dbo.Customer AS c LEFT JOIN dbo.OrderHeader AS oh ON oh.CustomerID = c.CustomerID WHERE oh.Orderdate > '2024/04/01' GROUP BY c.CustomerNameSee possible answers