January 2007 - Posts

.NET Code Generation Tools I've Tried

I was asked the other day, given that I have talked about IdeaBlade DevForce on my blog: what other code generators/object-relational mappers had I tried, and why did I eventually choose IdeaBlade?

I thought that might make an interesting blog post and had to go scratching around in my memory back to mid 2004, when I first thought to myself that there *might* be an easier way than writing repetitive routines to return datasets from hand-crafted stored procedures to access 40+ tables and then making the UIs for all of it ;-)

First, here's a brief list of some of the tools I've tried over the years (keep in mind that I should have posted this in 2005; most, if not all of the products I mention below will surely have evolved and improved over time):

  • Codus
  • RapTier $
  • LLBLGen $ - I was probably most impressed with this one, but it looked complicated :-)
  • CodeSmith $ - another good looking product but I thought it was overkill for what I needed. I also couldn't find many good, functional templates out of the box.
  • ORM.NET - I used this in a project while it was still owned by Olero, but was not completely happy - and when it went open source I kind of thought that it would die...how wrong I was!
  • OlyMars - at the time I evaluated it, this product mainly put out C# and had no active community support. I think the last version was old when I started looking.
  • WilsonORMapper $
  • MyGeneration

I'm not saying any of the above products were bad. I've put comments where I remember, but basically I was looking for the most value out of the smallest investment of my time - time which would include learning a new product.

As far as I can recall, I evaluated the tools with an eye for the following criteria, which I've roughly ordered in terms of my priorities. Points 4 and 5 will tell you a lot about where my head was at with regards to my needs and expectations:

  1. VB-oriented - or at least not VB-ignoring (at worst, VB-convertible)
  2. Adequate documentation and samples
  3. As easy to use as datasets - I like datasets; any new product I found needed to be easily able to replace the datasets in my projects
  4. I was looking for a product that would allow me to quickly put together an "administration interface" - basically something like MS Access so power users could add, edit and delete reference table data to their heart's content.
  5. I tended to steer away from tools which generated stored procedures for me - obviously, this had a lot of impact on the tool I chose
  6. Actively developed & maintained (not a one-off project) - you only have to search CodeProject to find the worn-out shells/interesting ideas of code generation past
  7. No requirement to buy into product X's way of doing things - at the time, I was just adapting to using the Data Access Application Block. I didn't want another major retro-active change, given that I was in active development.
  8. I wasn't particularly fussed if the UI was generated for me, especially after seeing the sort of UI that some of the tools generated.
  9. SQL Server support needs to be top-notch - I don't use Oracle, MySql, etc. so I'd rather have an SQL Server-centric tool that can utilise SQL Server fully, than a generic tool that codes to the lowest common denominator
  10. Not too expensive. Free is best.

Since then, my list would be expanded to include a .Net 2.0 version and the ability for the tool to easily support flowing through changes in the database to the UI (repeatable generation) without losing business rules or customisations I had done to the classes. Ideablade supports these last two (using partial classes).

After reviewing all of this, it seems fair to ask: did I get what I wanted? I'll have to leave that for another post...

Tags: orm, code generation

OT: 5 Meme

Adam Cogan tagged me in the "5 things that most people don't know about me" meme that's going around - thanks Adam...I was feeling left out :-(

So here is 5 random things that most people would not know about me:

  • I wanted to be an Air Force pilot when I was a kid - an eye test when I was 12 pretty much killed that idea (I remember hearing from a career counsellor "You could still be a navigator", and almost crying again). After that, I had no idea what I wanted to do, right up to starting Uni.
  • I have an Education degree from Monash - it's always been one of my plans to teach computing at high school, TAFE and eventually university level. I just want to make sure I've got something to teach first! I really only applied for teaching because one of my Year 12 teachers made an offhand comment that I'd make a good teacher.
  • I am *not* the Tom Williams that won "Dancing With The Stars" (a TV show on Channel 7 here in Australia) two years ago - just in case you were wondering :-)
  • I'm the oldest of 4 boys - my Mum still claims to this day that she always wanted 4 sons (well, she got 'em). Since I never had a sister, there's still a lot I don't know about girls! (Maybe *that's* the little known fact I should publish)
  • The most boring job I ever had was working on a computer help desk - my job description was "sit and wait until someone needs help", which left a lot of time for officially sanctioned & approved web surfing; however, even that got boring and in the end I'd take in a book to read while I was at work.

Here's 5 people I'd like to know more about (whether or not they tell me is up to them!):

Darren Gosbell at Random Procrastination
Karl Kopp at Karls Blog
Tejas Patel at Software and Tools
Nirav Patel at CodeLake
Greg Linwood at Transaction Blog

Tags: 5 meme