SQL Swimmer

Blog Post

Did you know?

Did you know that the call for speakers for PASS Summit 2016 opened on February 3, 2016?
Did you know that...

2016-02-15

451 reads

Blog Post

What is Power BI?

One of the “benefits” of being a chapter leader is that sometimes it means doing a presentation yourself when you...

2016-02-02 (first published: )

3,029 reads

Blog Post

What Do You Want?

It’s that time of year, planning for PASS Summit 2016.  We’ve already put out the Call for Volunteers, which closes...

2016-01-22

389 reads

Blog Post

We Want You!

It seems like PASS Summit 2015 was just yesterday and here we are again, getting ready for Summit 2016 already. ...

2016-01-08

425 reads

Blogs

How to Clear the SSMS Cache (SSMS 21 and Later)

By

How to Clear the SSMS Cache (SSMS 21 and Later) Updated...

The flight recorder: Replaying what an AI agent did on my SQL Server

By

“What exactly did it do on my server?” is the first question a DBA...

Announcements from the Microsoft Fabric Community Conference — Barcelona 2026

By

Microsoft shared a broad set of Fabric, Power BI, and SQL updates at FabCon...

Read the latest Blogs

Forums

Let's Talk Certifications

By Grant Fritchey

Comments posted to this topic are about the item Let's Talk Certifications

The Hidden Security Risks of Role Combination in SSAS Tabular

By Pablo Echeverria

Comments posted to this topic are about the item The Hidden Security Risks of...

The Empty Aggregate

By Steve Jones - SSC Editor

Comments posted to this topic are about the item The Empty Aggregate

Visit the forum

Question of the Day

The Empty Aggregate

I have this table in a SQL Server 2025 database:

CREATE TABLE [dbo].[CustomerOrder]
(
[OrderID] [int] NULL,
[CustomerID] [int] NULL,
[total] [money] NULL
) ON [PRIMARY]
GO
What is returned from this code? (answers are for the sum and then the count)
SELECT SUM(total) AS sum,
       COUNT(total) AS count
FROM dbo.CustomerOrder;



See possible answers