Blog Post

The Code Coverage Report

,

I had someone that told me recently that they needed to find a way to get code coverage in T-SQL. Not for them, not to improve quality, but because their manager wanted a report.

OK, here it is.

First, build a nice SSRS report that displays your company logo, a header, the current date, and a pie chart. Yes, I know pie charts are bad, but they’re good for managers that want something like code coverage.

Now, for the data source of the report, here’s your query:

SELECT 90 + ((RAND() * 8)-2)

Now, you won’t always get over 90%, which is what some people want, but you’ll get over 90 eventually.

Filed under: Blog Tagged: Humor, syndicated, T-SQL

Rate

You rated this post out of 5. Change rating

Share

Share

Rate

You rated this post out of 5. Change rating