Fix VS2010 solution and fix test to be compatible with at least SQL Server 2008