views:

103

answers:

5

I'm not a database admin or architect, so I have to ask those who do it 24/7. How established is the concept of an ORM (object relational mapping) in the world of database administration and architecture? Is it still happening, widely approved but still in its early stages, or is generally disapproved? I'm learning this area and would like to get a feel for whether it's going to be knowledge appreciated by the wider segment of this field.

+4  A: 

I can tell you from my experience. We are a $2.5B solar manufacturing company and we are basing our next generation of products on ORM technology. We're using Linq-To-SQL, quite successfully. We are very happy with it.

Randy Minder
Linq-To-SQL is not a complete ORM tool but LINQ to Entities (ADO.Net Entity Framework) is an ORM (Object Relational Mapper) API. Please refer here http://stackoverflow.com/questions/8676/entity-framework-vs-linq-to-sql
A_Var
@A-Var - "Complete" is subjective. Just because L2S is 1:1 with database tables, doesn't make it incomplete. In that sense, every ORM is incomplete compared to the product that has the most features, bells and whistles.
Randy Minder
+4  A: 

Widely used and definitely the present and near future. Database access through a handcoded layer of SQL generation was always fraught with drudgery and typos, and was unwieldy at best. ORMs let you use a persistence store in a programming way.

I thought this blog argued for it well: http://jonkruger.com/blog/category/fluent-nhibernate/ and SO posts like this (http://stackoverflow.com/questions/1114215/nhibernate-versus-llblgen-pro) show just how many people are using them.

Scott Stafford
+4  A: 

The concept has been around for at least 20 years.

If you take a look at any decent web framework, whether it's Java, Ruby, PHP, C# or Python, they all incorporate ORMs. Generally, it's perceived as being a more professional choice unless you have specific needs for high performance or custom SQL.

Alex JL
Re high performance, this isn't totally accurate. Many ORMs will let you use custom SQL if you want to take charge of performance occasionally.
samquo
Sure, it's good to point that out.
Alex JL
I guess my thought was, if you're using custom SQL your are pretty much just using the ORM to get a database connection, and it's not really using an ORM at that point.
Alex JL
+4  A: 

ORMs are widely used. Django (python web application framework) uses SQLAlchemy. Hibernate is popular for Java programs. ORMs make SQL application development faster, reduce the amount of boilerplate code that you must write, and hide which database you are using from the rest of the application. Performance may suffer using an ORM, so be prepared to customize things as needed.

Spike Gronim
+5  A: 

A lot of places are using them, that doesn't mean they are using them well or that they are a good idea for the long term health of the database. Doesn't mean they aren't either, usually it just means the people choosing them don't think about how this affects database design, maintenance and performance over time.

HLGEM