Tip: OVER and PARTITION BY
I like to repost this blog about once a year, because you really really need to know about windowing functions....
2012-11-28 (first published: 2012-11-26)
4,626 reads
I like to repost this blog about once a year, because you really really need to know about windowing functions....
2012-11-28 (first published: 2012-11-26)
4,626 reads
Last week at the PASS Summit, I had several conversations with several different aspiring bloggers, and found myself saying the...
2012-11-20
997 reads
A while back, I wrote a simple little query that lets you Get Index Included Column Info (because sp_help and sp_helpindex only...
2012-10-11
1,687 reads
Win Valuable Prizes!
Impress Your Friends!
This week we’re starting up a health and weight loss competition that I hereby dub #PASSGameOn,...
2012-10-10
981 reads
Last week, Sri Sridharan (Twitter, blog) and I sat down on the Internet to talk about his run for the...
2012-10-09
709 reads
Last week I received this comment/question from one of my fabulous First Timers:
I have a good natured question coming from...
2012-10-08
740 reads
Hi there ho there everybody! It’s less than five (FIVE!) three (THREE!)one (ONE!!) week until the 2012 PASS Summit in Seattle,...
2012-10-03
1,225 reads
On October 13, Dallas will hold our second ever Special Bi Edition of SQLSaturday Dallas - #SQLSat163 for you Twitter folk...
2012-09-14
1,092 reads
I can’t tell you how many times I’ve sat in a training room, in the middle of a week long...
2012-09-06
986 reads
Let’s pretend we’ve never met. Depending on who you are, maybe we haven’t. It’s beside the point, really.
So hi, I’m...
2012-09-04
933 reads
By Steve Jones
I’ve become an EV guy. I was talking with a friend who was selling...
By Steve Jones
A bit of a photo dump, but a few fun memories for me from...
By ReviewMyDB
Part 2 of my What's New in SQL Server for the Developer series. STRING_SPLIT,...
Comments posted to this topic are about the item How to connect your SQL...
Comments posted to this topic are about the item Finding the Black Friday Sales...
Earlier this week I had an issue with a Win 8.1 laptop I was...
We are tracking sales for Black Friday today. We have these aggregate values:
CREATE TABLE dbo.BlackFridaySales
(
Product NVARCHAR(50) NOT NULL PRIMARY KEY,
Units INT NOT NULL
);
INSERT INTO dbo.BlackFridaySales (Product, Units)
VALUES (N'55" TV', 900),
(N'Air Fryer', 500),
(N'Noise-Cancel Headphones', 500),
(N'Robot Vacuum', 300);
I'm trying to get a ranking of the sales that would return 1, 2, 2, 3 for the product levels. Which query does this? See possible answers