T-SQL Tuesday #36 – Community
Chris Yates (@YatesSQL / blog) is hosting the T-SQL Tuesday blogging party this month, and he wants to know “What does...
2012-11-13
732 reads
Chris Yates (@YatesSQL / blog) is hosting the T-SQL Tuesday blogging party this month, and he wants to know “What does...
2012-11-13
732 reads
The Myth
One misconception that I see a lot deals with how data is stored in a clustered index. Specifically – is...
2012-10-21
8,149 reads
The Scenario:
You just restored a production database on a development server. You’ve told the developers that it’s restored, and you...
2012-10-03
2,717 reads
Hello? Mr. DBA? Have you got a moment?
So there you are, enjoying one of the few quiet moments of your...
2012-08-15
5,305 reads
Late last year, my life got strange. Well, it’s always been strange, so let’s just say it became stranger than...
2012-07-18
747 reads
The PASS Summit 2012 schedule has been released, and I’m proud to announce that I’ve been selected to present a...
2012-06-25
684 reads
Lately, I’ve been asked by several folks about the interview questions that I use when I interview candidates for SQL...
2012-06-15 (first published: 2012-06-11)
11,973 reads
ORM tools. They’re great. They’re evil.
In the right hands, used the proper way, they can be a very powerful, very...
2012-06-11
3,489 reads
Next up on the SQL Server 2012 Performance testing circuit: Gap Detection. You know, where you find missing values from...
2012-04-19
3,291 reads
This month, T-SQL Tuesday is being hosted by Nigel Sammy. Since the RTM of SQL Server 2012 just occurred, he...
2012-04-10
1,618 reads
By Steve Jones
I type fairly well. Well, I type fast, but I do wear out a...
By ReviewMyDB
Index maintenance has always meant nightly jobs and a window you have to defend....
I’m sure you’ve all heard the tale of Goldilocks and the Three Bears, but...
Comments posted to this topic are about the item SQL Art, Part 4: Happy...
Comments posted to this topic are about the item How We Handled a Vendor...
Comments posted to this topic are about the item Cognitive Coverage
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 NULLAll 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