LessThanDot Site Logo

LessThanDot

A decade of helpful technical content

This is an archive of the posts published to LessThanDot from 2008 to 2018, over a decade of useful content. While we're no longer adding new content, we still receive a lot of visitors and wanted to make sure the content didn't disappear forever.

SQL Advent 2011 Day 1: Date and time

In my Are you ready for SQL Server 2012 or are you still partying like it is 1999? post, I wrote about how you should start using SQL Server 2005 and SQL Server 2008 functionality now in order to prepare for SQL Server 2012. I still see tons of code that is written in the pre 2005 style and people still keep using those functions, procs and statements even though SQL Server 2005 and 2008 have much better functionality.

Read More...

How to get information about all databases without a loop

Quite often we want to consolidate query information across all databases (or all user databases). When this question is asked in forums, the usual recommendation is to either try running undocumented sp_MSForEachDB stored procedure or do a loop and use dynamic SQL. The example of such stored procedures can be found, for example, THIRD EXAMPLE – SPROC to enumerate all objects in databases. The idea occurred to me last night that while we do need a dynamic SQL to solve this problem, we don’t really need a loop unless we need a second loop involving looping through all tables.

Read More...

Anecdotes about SQL AKA post 400

This is my 400th blog post here on lessthandot and I decide to steal borrow Chrissie’s idea and ask a bunch of people if they have an interesting story to share about SQL. Here is how I asked it As you may or may not know I’m an avid SQL fan. I’m in the process of writing my 400th blogpost on lessthandot and I thought I would make it a little special and ask some special people about their experience with SQL.

Read More...

People about VB.Net

This is my 400th blogpost here on Lessthandot. Normally one would tell the world about their best and worst posts and come to the conclusion that they are brilliant and having fun doing this blog thing. Alas, it will not be so this time. I thought it was time to ask some other people to do the work for me. I sent this question a few people I know. Dear <firstname>,

Read More...

Are you ready for SQL Server 2012 or are you still partying like it is 1999?

SQL Server 2012 is around the corner, perhaps you are ready to upgrade and perhaps you are not. Maybe you just have upgraded to SQL Server 2008 R2 without software assurance and thus you don’t qualify for SQL Server 2012 upgrades.. Even though most people are on SQL Server 2005 or higher these days, I see plenty of database code that is being written today in SQL Server 2000 syntax; I guess old habits are hard to break indeed!

Read More...

Teamcitysharp v0.1 released

The always amazing Paul Stack has released his very first edition of teamcitysharp and I though it a good idea to try it. If you don’t know what teamcity is then you are missing out. No need to hold back either since it is free for personal use and some other uses. For people that use Teamcity it is always useful if you can spread your stats around and show the managers what you are doing and how good you are doing.

Read More...

The EndlessLoopQueue

I named it EndlessLoopQueue because I couldn’t think of another name for it. You can put items on this queue but when you enqueue an item it will be re-added to the end of the queue therefor you will end up in some kind of endless loop (hence EndlessLoopQueue, yeah I am kinda clever). It’s possible that this exists but I could not find it in the .Net 4.0 Framework.

Read More...

Differences between Autofac and Structuremap with VB.Net the use of Lazy(Of T)

One of the things that can burn you when using an IoC container is that if your objectgraph is big than it will take some time to instantiate everything at the startup of your application. But why would we not use Lazy(Of T) to prevent this? After all that is what Lazy(Of T) is for. To lazy initialize your objects. Of course our IoC container must be able to handle this.

Read More...

Differences between Autofac and Structuremap with VB.Net

So after deciding to learn Autofac. First of all I made a few classes and an interface. Public Interface Interface1 End Interface Public Class Class1 Implements Interface1 Public Sub New() Console.WriteLine("Instantiated Class1") End Sub End Class Public Class Class2 Public Sub New() Console.WriteLine("Instantiated Class2") End Sub End Class Public Class Class3 Public Sub New(ByVal i1 As Interface1) Me.I1 = i1 Console.WriteLine("Instantiated Class3") End Sub Public Property I1 As Interface1 End Class``` And then I wrote some tests using structuremap.

Read More...

Picking a new IoC container/Replacing structuremap

I have been using Structuremap for years now. Which is obvious since I have 28 blogpost mentioning it. The first of those posts going back all the way to 2008 (Considering I only started blogging in 2008. Anyway I have been using structuremap with great success since the beginning. But frameworks are like handbags. Once you have it long enough you just want a new one. Not only to brag about it with your girlfriends but sometimes just have something new and shiny that fits better with that new pair of shoes you bought.

Read More...