SQL SERVER Fast Running Totals solution with ordered CTE update? Who says you need a cursor to get a running total? I’ve typically done these kinds of things with expensive CROSS JOINs and/or nasty INNER JOINs. Good to know there’s a nicer way. Extended Events Manager Update: Now A SSMS Addin SQL 2008 Extended Events are a powerful new way of troubleshooting problems with SQL Server. One short coming is that there is no UI support for this new feature.
I work in isolation. I don’t mean physical isolation – I have coworkers and we talk and go to lunch and do all kinds of coworker things. I work in physical isolation from other practicing database professionals. My manager is a former DBA, but he hasn’t worked with SQL Server newer than SQL 2005 and most of his experience is with SQL 2000 and Oracle as a developer. The vast majority of the time, this isn’t an impediment to what I do – I have IM, email, twitter, and forums to keep me immediately in touch with my peers.
SQL SERVER Learn Microsoft BI So you want to learn all about the BI, do ya? Lots of videos. Lots and lots of videos. They’re all free. Getting a NEWSEQUENTIALID() How do you get the ID that’s created after an insert if you’re using NEWID() or NEWSEQUENTIALID()? Pat Wright has the answer! (Hint: The answer is not “a taco truck”.)
DEVELOPMENT Nobody Hates Software More Than Software Developers I couldn’t agree with Jeff more.
First off, I want to say thank you to the Central Ohio .NET Developers Groupfor giving me the opportunity to speak last night. I really enjoyed it and I was glad that I could share some of the things that I’ve learned with such a great group of people. Everyone at CONDG was very welcoming, as they always have been, and the questions from the audience were fantastic. It’s always good to hear that I’m not the only one who has run into some of the scenarios I mentioned in the presentation, and it’s also always great to hear real life success stories from developers who have made use of the techniques that I’m speaking about – in this case NHibernate.
Here are the slides and sample code from my recent presentation “From Tables to Objects” that I gave at the Central Ohio .NET Developer Group. To those who did not attend, you can skip the rest of this post unless you want some NHibernate and SQL Server resources. NHForge – this is the project home page for NHibernate. Fluent NHibernate – download Fluent NHibernate. NHProf – NHibernate Profiler NH Contrib – Additional, non-core, NHibernate libraries, includes NHibernate.
I’ve been slacking on the blogging front. Which is a shame, because I’ve been busy doing some really fun things recently. Want to know about one of them? I hope you do, because I’m going to talk about it regardless. I spent last weekend at the Columbus Give Camp. What was the point of this? Well, the point of Give Camp is for a bunch of geeks to get together and help out various charities.
SQL SERVER File/Folder/Share Permissions for DBAs and Database Developers So you thought you knew everything you needed to know about security? Take a look and make sure your assumptions were correct. Groovy Baby, Yeah Tony Bain hits up the sweet spots from Groovy Corp’s press release for a new relational database platform. New DB?!? That’s right a new, in memory, RDBMS.
DEVELOPMENT The Law of Demeter Is Not A Dot Counting Exercise Phil Haack gives the best explanation I have ever read for the Law of Demeter, which is oft quoted by developers and oft misunderstood by me.
I’m in the process of finishing up a presentation for the Central Ohio .NET Developers Group, and this got me to thinking about how I structure my presentations. Luckily, right around the time I was musing on this subject I ran across Jeff Atwood’s article Who Needs Talent When You Have Intensity?(which lead to Users shouldn’t think about YOU). I’ve long held the opinion that a good presentation is one that is immediately useful in your day to day work.
SQL SERVER Object Naming Standards Scott Herbert put up an overview of the naming standards that he uses. Like the obnoxious lout that I am, I commented. The point is, of course, to use naming standards. Take a look at Scott’s for an example. No SQL There’s a big hullabaloo going on about this whole “No SQL” movement. Here’s Andrew Fryer’s take on it. Performance Counter for SQL Server Ever want to know what those performance counters actually mean?
Have you ever wanted to get a running total of all of the descendants of each tree node? This sort of thing is useful, especially if you don’t want to pull back an entire object graph just to compute the count of a child collection.``` IF OBJECT_ID(’tempdb..#categories’) IS NOT NULL DROP TABLE #categories;
IF OBJECT_ID(’tempdb..#product_categories’) IS NOT NULL DROP TABLE #product_categories;
CREATE TABLE #categories (CategoryId INT, ParentCategoryId INT); CREATE TABLE #product_categories (CategoryId INT, ProductId INT);