• diegosiao (8/27/2015)


    I agree.

    To a "from zero" robust corporative application, I think code-first oriented modeling is a good approach, taking advantage of the SQL script generation to revise it and then execute with appropriated corrections (or not, hopefully).

    But as long as you're going with a code-driven, object-driving database model, you're looking at major issues. It really doesn't work well. You have to approach both toolsets as they're designed and as they work. Trying to force the models and methods of one, the application code, on the other, the relational storage engine, will lead to failure.

    I'm not against ORM use. I've seen it work quite successfully. However, I've also seen it fail spectacularly and the failures were because the database and relational storage were not taken into account appropriately.

    "The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
    - Theodore Roosevelt

    Author of:
    SQL Server Execution Plans
    SQL Server Query Performance Tuning