# Friday, December 28, 2007

ReSharper 3.1 just came out, and of course I immediately installed it.  So far so good.  It fixed a couple of annoying crashes for me and added a new feature.

  • I can now open my MSBuild project files without ReSharper crashing constantly.
  • Visual Studio has yet to crash on exit.
  • And the best reason to upgrade: solution wide error analysis has been added.  Pic below.

ReSharperErrorsInSolution

Friday, December 28, 2007 2:17:52 AM (GMT Standard Time, UTC+00:00)  #    Disclaimer  |  Comments [0]  | 
# Thursday, December 27, 2007

Today at work we needed to compare the contents of a SQL table against an FTP directory.  We originally had a process that involved a lot of steps using Excel, NotePad, and command line FTP.

You could create a PowerShell script that iterates the SQL Server data and verifies each file is on the FTP server. This seemed like it would be slow so I opted for running FTP directly from my query (assuming you have xp_cmdshell enabled). Here's an example. Notice it's getting the FTP commands to run from the ftpoptions.txt file.

declare @FilesOnDisk table

(

[File] [nvarchar] (50)

)

 

insert into @FilesOnDisk ([File]) exec xp_cmdshell 'ftp -A -s:c:\temp\ftpoptions.txt ftp.microsoft.com'

 

select * from @FilesOnDisk where [File] is not null

 

Now we can join this temp table data to our local SQL Server table to find missing files on the FTP server...

Thursday, December 27, 2007 5:12:35 PM (GMT Standard Time, UTC+00:00)  #    Disclaimer  |  Comments [0]  | 
# Monday, December 24, 2007

There's a discussion around lines of code (LOC) and code base complexity right now, and I had commented about one the better code bases that I maintain was around 80K LOC, as compared to a much smaller code base that I maintain.  80K was just a guess at the time, but the engineer in me wanted hard numbers.  I downloaded .NET Line Count Utility from CodeProject and pointed to our back end server solution (yeah it takes sln and csproj files as input!).  To my surprise I had guessed the # LOC within 35 lines.  The actual number was 80,035 LOC.  Either I'm good at estimating LOC, or more likely I just got lucky.

Monday, December 24, 2007 7:42:13 PM (GMT Standard Time, UTC+00:00)  #    Disclaimer  |  Comments [0]  | 
# Thursday, December 20, 2007

I encountered a really annoying bug in the SQL Server SMO scripting library today.  Once you script out a single "DROP" script the internal scripter is left in a bad state and starts throwing NullReferenceExceptions on any subsequent call to the Script method.  I haven't found a good way around this yet.  Unfortunately the only reference I can found about this issue confirms the bug but nothing else.  Hopefully this will be fixed in SQL Server 2005 SP3, because it sure isn't fixed in SP2.

Thursday, December 20, 2007 8:43:15 AM (GMT Standard Time, UTC+00:00)  #    Disclaimer  |  Comments [0]  | 
# Friday, December 14, 2007

Data binding DateTime fields in MonoRail is pretty powerful and flexible, but not really straight forward.  Most of the time you can just provide the domain object propery as an argument to the a form helper method, but with DateTime's split across multiple select boxes this doesn't work when you post back to your controller method.  To get DateTime's to work across several HTML select fields you need to explicitly provide the selected value like so:

$Form.Select("billing.accountExpiration", $billing.accountExpiration.Month, [1..12], "%{tabindex='11'}")
$Form.Select("billing.accountExpiration", $billing.accountExpiration.Year, [$DateTime.Now.Year..2011], "%{tabindex='12'}")

Friday, December 14, 2007 6:50:05 PM (GMT Standard Time, UTC+00:00)  #    Disclaimer  |  Comments [0]  | 

I asked the alt.net group what issue/feature tracking software everyone would recommend, and thankfully I got a lot of responses about what people are using or have used in the past.  Really useful stuff.  It would take an individual years to glean this kind of first hand experience.  Here's a summary of recommendations (good and bad):

  • TRAC - Python based OSS app. It seemed a lot of people have used this.  Most people think it's OK, but the consensus is that it's kind of "wonky" at times.  The UI isn't particularly pleasant, but Ayende did create a simple Winform UI for it at one point - not sure it still works or how well.
  • Mingle - Developed by ThoughWorks.  ROR app.  The UI is pleasant and customizable.  The pricing is different, it seems you pay monthly.  Wave of the future, especially for software that gets released frequently (permanent beta)?  Compared to the competition this appears to be a rather expensive option - but possibly worth it.
  • FogBugz - The UI is pretty simple/clean, and has a good dashboard.  I liked the fact that is contained "evidence based tracking" which sounds really smart and useful - as long as everyone enters their actual time on a task accurately.  Phil Hack said, "...FogBugz is hands down awesome. Anyone that disagrees with me, you're wrong. End of story."
  • StoryVerse - MonoRail reference project or real OSS based project?  The code AND the UI look really clean.  I'm not sure if this is still active or how full featured it is, but it definitely looks promising.
  • Gemini - Got some mixed reviews, but I think most people gave it a +1.  It looks like a lot of companies are using this one.  Integrates great with SVN.  The screenshot of the home page reminded me of Jira.
  • Elementool - Fairly cheap.  Free version fields.  From Donn, "Unintuitive and just a hassle to use. Never integrated it with anything though. I wouldn't want to. I just want to STOP using this product."
  • Lighthouse - Looks like a hosted ROR app?  From Brian, "It has rough edges in some areas, but overall is a very nice interface, and you can use email to create and comment on issues.  It only has ONE status field (which at first seemed limiting, but then I realized was liberating - at least for this project).  If all you are doing is tracking open items (for example on a maintenance project) it may be all you need."
  • TargetProcess - ASP.NET agile management tool.  It will manage bugs, features, and support tickets.  It integrates with SVN.  What's cool is that it uses NHibernate to data access, so it appears you could use any RDMS that NHibernate supports.
  • BugTracker.NET - This is a very simple OSS ASP.NET app, but one look at the code you'll run screaming. 
  • AxoSoft - TODO: more info
  • MS Project Server - It's "enterprisey".
Friday, December 14, 2007 8:15:46 AM (GMT Standard Time, UTC+00:00)  #    Disclaimer  |  Comments [1]  |