For the sake of argument, how do I convince someone that Linq2Sql is much better than the Application Application Block in an Asp.Net MVC project?

How do I convince someone that Linq2Sql is much better than Application Application Block in an Asp.Net MVC project?

+2


source to share


5 answers


Seriously, if you don't know why this is better, why do you think you have the ability to convince someone else?

I don't mean to neglect you, but most people claim that something will do it because they believe that it is true (presumably for some reason or reasons), something that is not there.



I mean, I could try to convince you that C # is a better language than F #, but I will be wasting my time. My knowledge of this is almost non-existent.

+6


source


I'll take a hit on it:

One of the reasons is that you will get strong typing on your data. Switching from a loop to dr ["column"] with various rolls to pull a strongly typed object is a breath of fresh air. Catching compile-time data access errors is great.

You can of course do the same with an object layer above your sql, but basically you will get a shadow of what linq2sql gives you out of the box.

Also, think about the time you save by allowing linq expression trees to generate sql vs by coding it all by hand. the initial pass won't be bad, but refactoring the database is a pain, once you have to modify every access to it.



Combine this with defining canonical data relationships in one place, and it's no surprise that a lot of people have moved from direct sql access to linq2sql.

change

In my experience, resistance to trying new things comes from the fear of leaving something you understand for something you don't have. I am assuming that you will get the best welcome from your colleagues if you create a small demo that follows a simple scenario. Build it up in front of you and explain each step. Show the generated sql at the end and let them examine it. They will have much better information for your overall decision.

+1


source


"Better" depends on your situation. Are you sure this is really "better"? Maybe the person you are trying to convince is right and you are wrong?

What's your specific situation?

0


source


If it is indeed much better for your project, then it should be easy for you to make a clear list of the pros and cons of each approach as it applies to your situation.

Then set up a meeting with all stakeholders and present your case.

0


source


So, one person who doesn't know why wants to help convince another person who doesn't know why. Both people know what they want, without a clue why.

For me it is a nobleman. Stick with what has already passed until nothing good is proven. And to prove that something is better, you need to understand what you have and what you are comparing to.

0


source







All Articles