
Pete Tonkin
@sql_pete
Be good to your data, and it'll be good to you.
You might like
[Blog] : Advanced report examples using PIVOT and GROUPING SETS I show how I combine GROUPING SETS and PIVOT to get crosstab-style reports without Excel. mssqltips.com/sqlservertip/7…
![AaronBertrand's tweet image. [Blog] : Advanced report examples using PIVOT and GROUPING SETS
I show how I combine GROUPING SETS and PIVOT to get crosstab-style reports without Excel.
mssqltips.com/sqlservertip/7…](https://pbs.twimg.com/media/FNQOSkwWYAI-CdZ.jpg)
There’s a special place in hell for people who name their sub-directories in the MMM-YY date format. #baffled
If I had 50p for every time I forgot that UNION (as opposed to UNION ALL) does an implicit DISTINCT behind the scenes, I’d have well over £5 by now.
If you ever find yourself having to use DATETIMEOFFSET in SQL Server, can I recommend (a) holy water, (b) finding a less stressful job; base-jumping with live tigers strapped to you, maybe.
New essay by me in the New Yorker. When it comes to data - in order to count - one must first decide what should be counted. newyorker.com/magazine/2021/…
newyorker.com
What Data Can’t Do
When it comes to people—and policy—numbers are both powerful and perilous.
Good morning! I constantly feel like a fraud. I know a few of you do too. I'm told it's normal. The principal key to dealing with this is simple: Fake it till you make it. Just do the work. Pretend you are what you are not and do the work.
New blog post: “Practical queries using binary operations” sqlpete.wordpress.com/2021/02/03/pra…
Importing data into #AzureSQL is a common task: I have created a repo to provide working code samples to that task easy and quick. Powershell, AZ CLI, BCP, BULK INSERT, Data Factory and Apache Spark are all covered. Enjoy! lnkd.in/dbnRwxs
New blog post: ‘Interest and APR: a short explainer’ sqlpete.wordpress.com/2020/12/31/int…
This was a really informative watch, recommended!
[From the best of the blog archives:] 7 Ways Your Data Is Telling You It’s a Graph by Karen López (@datachick) Read now: r.neo4j.com/2J1h4kS #GraphDatabases #DataModel #GraphDataModel
Ok, this is too much. “the introduction of LAMBDA makes the Excel formula language Turing Complete” techcommunity.microsoft.com/t5/excel-blog/… tl;dr LAMBDA() lets you name any Excel formula you have written so you can then simply call it by name.
[From the best of the blog archives:] 7 Ways Your Data Is Telling You It’s a Graph by Karen López (@datachick) Read now: r.neo4j.com/2J1h4kS #GraphDatabases #DataModel #GraphDataModel
The GREATEST holiday gift that you LEAST expected... reddit.com/r/SQLServer/co… Happy holiday everyone!

Turns out my definition of “self-join” is NOT the same as SQL Server’s ; you can’t join to the same table twice in an indexed view, which has ruined my morning’s work!
Every day, it kills me that you can’t do cross-db joins in Azure. It’s like trying to run a race with your legs tied together.
“Normalise until it hurts, denormalise until the devs stop whining.”
United States Trends
- 1. Lakers 94K posts
- 2. Luka 71.5K posts
- 3. Ayton 15.5K posts
- 4. Marcus Smart 8,720 posts
- 5. #MLBS6Spoilers 6,088 posts
- 6. Pharos 9,747 posts
- 7. Froot N/A
- 8. Steph 33.8K posts
- 9. Warriors 96.9K posts
- 10. Rockets 59.8K posts
- 11. Draymond 8,758 posts
- 12. #DWTS 49.4K posts
- 13. #DubNation 13.4K posts
- 14. Reaves 9,307 posts
- 15. Jimmy Butler 9,859 posts
- 16. Shai 34.2K posts
- 17. Sengun 26K posts
- 18. Double OT 6,821 posts
- 19. #MOST_WANTED_IN_OAKLAND N/A
- 20. LeBron 36.8K posts
Something went wrong.
Something went wrong.