Tag Archives: testing

Unit Testing T-SQL Code

Abstract Unit testing has become an integrated, expected part of most software development teams. Many database developers have yet to implement unit testing as a regular habit. This session will look at two-unit testing frameworks and show how to implement … Continue reading

Posted in Presentations | Tagged , | Leave a comment

SQL Grouping on Sums (with testing)

I ran across a post recently that I thought was an interesting T-SQL problem. The user wanted to group values into a running total, but the groups would reset based on a sum. In this case, the user had this … Continue reading

Posted in Blog | Tagged , , , | Leave a comment

Using tSQLt to Find Min/Max Times

I love tSQLt. It’s a good way to write tests that can determine if your code is actually working. Since I’m a fan of unit testing, I think using tests to verify your logic is great. What’s excellent with tSQLt … Continue reading

Posted in Blog | Tagged , ,

Detecting Issues

Here’s a simple question: how are more of your application issues detected, by people or systems? I bet most of you initially think of your monitoring systems and the automated messages or pages that are sent out regularly as detecting most, … Continue reading

Posted in Editorial | Tagged ,

Writing the Correct Query is Important

There’s a saying in the data world: garbage in, garbage out. We use that when we can’t get good information from our database because the data we’ve stored isn’t as useful as we would like. That’s a problem, and it’s … Continue reading

Posted in Editorial | Tagged , ,

Where’s the Unit Testing?

I’ve been a proponent of Unit Testing, especially for databases. I’ve given presentations on the topic and advocate the use of techniques to verify your code works, especially over time when the complexity grows, new developers change code, and potentially … Continue reading

Posted in Editorial | Tagged , ,

Quick Tests for a Function

I was writing a poorly performing UDF the other day and then wanted to replace it with a better performing one. However, I wanted to be sure that the function was the acting the same externally. In other words, does … Continue reading

Posted in Blog | Tagged , , ,

What’s Your Test Plan?

I ran across a post on upgrading a SQL Server instance, where the original poster (OP) was asking about a document to upgrade from SQL Server 2008 to 2014. That’s a big ask, especially as not many documents tend to … Continue reading

Posted in Editorial | Tagged , ,

Testing T-SQL Made Easy

Abstract: Everyone tests that code, but most people run a query, execute a procedure and run another query. This ad hoc, non-repeatable testing isn’t reliable, and encourages regression bugs. In this session you will learn how to begin introducing testing … Continue reading

Posted in Presentations | Tagged , ,

Quick Tests–Function Returns

I ran across a neat piece of code recently from Gail Shaw. She answered a question on returning the base path from a path in a string. Meaning if I had this string: c:\Users\Sjones\Documents\text.txt I’d want to return this: c:\Users\Sjones\Documents … Continue reading

Posted in Blog | Tagged , , ,