Blog Posts

Blog Post

A New Word: 1202

1202– n. the tipping point when your brain becomes so overwhelmed with tasks you need to do, you feel too guilty to put anything off until later, prioritizing every...

2024-03-29

41 reads

Blog Post

DevOps: It’s About the Team, Not Just the Tech

In November 2023 I did a session at PASS Summit and one of my sessions was voted https://passdatacommunitysummit.com/about/news/have-you-watched-some-of-the-most-popular-sessions-from-summit-2023/ That session was called DevOps is about Growing People rather than...

2024-03-27 (first published: )

204 reads

Blogs

AI Helps Me with My Sloppiness

By

I type fairly well. Well, I type fast, but I do wear out a...

Automatic Index Compaction

By

Index maintenance has always meant nightly jobs and a window you have to defend....

The Goldilocks problem – Materialized Views

By

I’m sure you’ve all heard the tale of Goldilocks and the Three Bears, but...

Read the latest Blogs

Forums

SQL Art, Part 4: Happy 4th of July — A British DBA's Guide to Celebrating a War We Don't Talk About

By Terry Jago

Comments posted to this topic are about the item SQL Art, Part 4: Happy...

Alamat Kantor BCA KCU A. YANI Telp/Wa 0817839777

By layanan_Bca88

Hubungi Cs: 0817844112 Jl. A. Yani No.656-658, Cicaheum, Kec. Kiaracondong, Kota Bandung, Jawa Barat...

Alamat Kantor BCA KCU BANDUNG Telp/Wa 0817839777

By m4rt1n4

Hubungi Cs: 0817844112 Jl. Asia Afrika No.122-124, Paledang, Kec. Lengkong, Kota Bandung, Jawa Barat...

Visit the forum

Question of the Day

Getting the Average

I have this data in the dbo.Commission table in a SQL Server 2022 database.

salesperson commission
Brian       12
Brian       16
Andy        7
Andy        14
Andy        21
Steve       20
Steve       NULL
All the data is a varchar, and I decide to run this query to get the totals for each salesperson.
SELECT SalesPerson
     , AVG(TRY_PARSE(Commission AS int)) AS TotalCommission
 FROM commission
 GROUP BY SalesPerson
GO
What average commission is calculated for Steve?

See possible answers