Five Reasons for Using an O/R Mapping Tool

So, why should you use any O/R mapping tool? I am not talking about a specific tool but rather all O/R mapping tools in general. There are a number of reasons for using an O/R mapping tool but before I dive into that, let me give you a brief overview of what an O/R mapping tool really is.

An O/R mapping tool generates persistence objects for your .NET application. It is a modeling and code generation tool that connects to your database and reads its schema, then lets you map objects to database tables and views, specify single-row insert, update, load, and delete operations, queries and stored procedure calls, as methods to these objects. And, it also lets you define one-to-one, one-to-many, many-to-one, and many-to-many relationships between objects based on relationships between tables in the database. It then generates fully working persistence objects code for you.

There are many other features that a good O/R mapping tool provides but I'm keeping my description brief so I can talk more about the benefits.

Reason 1: Cuts down your development time

First benefit of an O/R mapping tool is that it saves you a ton of development time (20% to 50% time depending on your situation). Now, O/R mapping tool is not generating any "rocket science" code for you and you could definitely do it manually if you wanted. But, this is a lot of tedious work and you would definitely be happier if you didn't have to do it yourself. Let's do some simple math.

A typical application with 15-20 database tables has 30-50 objects (including domain and factory objects) and this is roughly 5000 to 10,000 lines of code. It is likely to take you a few weeks to a couple of months to develop and test this code. And, if your application has more tables than this (which many do), then just multiple the above numbers by that much.

On the other hand, an O/R Mapping tool would generate this code for you in a day or two. Even here, you need these 1-2 days primarily to determine your object mappings to the database. The actual code generation is instantaneous. So, your time saving is tremendous.

Reason 2: Produces better designed code

Second benefit of an O/R mapping tool is that it lets you produce better designed code than doing it yourself by-hand. I know what you're thinking. You think you can do a better job than an O/R mapping tool because you write every aspect of your code. Some of you definitely can but not everyone. Consider this. An average development team has different levels of expertise and experience and not everybody is a good designer. As a result, they may not follow design patterns in their code and end up with a lesser quality code. And, if multiple developers are writing code, their code is very likely going to be inconsistent with each other. And, inconsistency itself is a big source of poor quality in an application's code.

On the other hand, a good O/R mapping tool uses code templates that have excellent design because they are very likely designed and created by very senior (architect level) engineers. And, these code templates almost always follow known design patterns. So, the code that you'll generate from an O/R mapping tool is very likely going to be better designed than code designed by your own development team.

Reason 3: You don't have to be a .NET expert

Third benefit of using an O/R mapping tool is that you don't have to be a .NET expert to develop your persistence code. As you know, data access code is critical for the overall performance of your application. If this code is designed and developed poorly, it can severely affect your application. So, if you developed this code by hand, you need to be an export of .NET, COM+, stateless components, and MTS.

However, if you use an O/R mapping tool, you can focus primarily on the "logical design" of your persistence objects including object mapping and the different types of interactions with the database including insert, update, load, delete, queries, stored procedure calls, relationships, and more. And, the O/R mapping tool would do the rest for it. It would ensure that the generated code follows all the best practices of writing stateless .NET components to run in COM+ and MTS.

Reason 4: Saves you testing time

Fourth benefit of an O/R mapping tool is that it reduces your testing effort dramatically. If you developed all the persistence code by hand, you would also be responsible for testing it yourself. And, as you know, testing is as much effort as development in any project.

On the other hand, if you generated code from an O/R mapping tool, it is coming from code templates that are very likely thoroughly tested by the software vendor itself (more so than you because it is their primary focus). And, on top of it, most likely hundreds or perhaps thousands of other customers are using this tool and have tested the code generated from this O/R mapping tool. As a result, many of the bugs that you might not find in your own testing have already been found and fixed in the generated code of an O/R mapping tool.

Reason 5: Simplifies your .NET development

If you have to write all the persistence code yourself, you're bogged down into the details of ADO.NET, COM+, MTS, stateless .NET components, and more. And, you end up spending a lot of time in details that you really don't need to. On the other hand, if you generate code from an O/R mapping tool, you get well design objects and you only need to deal with their public interface.

Below is an example of code you'll write if you used an O/R mapping tool.

try {

Employees objInfo = new Employees();

EmployeesFactory objFactory = new EmployeesFactory();

objInfo.EmployeeID = EmployeeID;

objFactory.Load(objInfo);

// code here to use the "objInfo" object } catch(Exception ex) {

// code here to handle the exception

return; }

As you can see, the generated code is very simple to use than actually writing the .NET components yourself.

Many people have never heard of O/R mapping tools and many more have heard of them but are afraid to use them. I hope I have made a strong enough case here for you to give a serious consideration to O/R mapping for your project.

Iqbal Khan is the Director of Sales & Marketing at AlachiSoft (http://www.alachisoft.com/), a leading provider of O/R Mapping tool called TierDeveloper. You can reach him at http://www.alachisoft.com/.

expert residential cleaners Park Ridge ..
In The News:

The Omoway Omo X features a modular design, obstacle detection and emergency braking, and can drive itself to charging stations, signaling the future of smart urban mobility.
PillTrek, a tiny wireless smart capsule created by Caltech, provides real-time gut health data by detecting electrolytes, metabolites, glucose, hormones, pH levels and temperature.
Learn to spot fake bank text messages with five warning signs of Chase phishing scams, including suspicious links and urgent deadlines designed to steal your account information.
Robot coyotes built on motorized cars reaching 20 mph are being deployed at military airfields as an innovative solution to wildlife threats to aircraft safety.
Explore Google Drive's strengths and weaknesses as a backup solution, including its encryption security, privacy concerns and comparison to dedicated backup tools.
As environmental challenges grow, underwater habitats gain momentum with DEEP's Vanguard, supporting short missions and Sentinel designed for 28-day stays at depth.
The new Urban Eyes safety vest features dual cameras, reflective panels and a wireless remote to deter harassers and provide peace of mind for outdoor workouts.
The $200 billion data broker industry tracks your personal details across websites, posing privacy risks that can be mitigated through data removal services.
UCC Holding has teamed up with COBOD to create desert-inspired, 3D-printed schools in Qatar, featuring dune-like wavy walls impossible with conventional construction.
Darkling beetles equipped with microchip backpacks can be guided through disaster areas using electrical signals, offering a biological solution for search and rescue.
Scammers use number porting to take control of outdated landlines still connected to financial accounts, bypassing two-factor authentication to steal funds while avoiding detection.
Twitter co-founder Jack Dorsey developed Bitchat, a privacy-focused messaging app that works offline via Bluetooth without requiring email, phone numbers or personal data.
Google is making a push to ensure its AI, Gemini, is tightly integrated with Android systems by granting it access to core apps like WhatsApp, Messages, and Phone.
A new green energy system is set to change how we capture clean power, and it all starts with the ocean. French startup Seaturns has designed technology that taps into the natural motion of the sea.
Cybersecurity researchers are warning that hackers have started exploiting flaws in chatbots to carry out AI phishing attacks.
Google has just made it easier than ever to regain control of your inbox with Gmail's new Manage Subscriptions tool.
Despite the benefits, residential power saver programs come with several potential drawbacks and concerns that have been raised by both customers and experts.
The Blackdot AI tattoo machine is quiet. It's steady. And according to early users, it hurts a lot less.
Attackers have started to exploit the very signals that users assume will keep them safe when it comes to add-ons to improve productivity or entertainment.
Located on Cerro Pachón in Chile, the world's most powerful digital camera is set to transform how we see the universe.
The innovative DQ Tower stands 28 feet tall with 420 square feet of living space, featuring floor-to-ceiling windows and premium amenities in a prefabricated design.
A new mmWave imaging system allows warehouse robots to scan and create 3D models of objects inside sealed containers, potentially revolutionizing shipping processes.
Family fraud endangers seniors when relatives exploit their trust, but removing personal data online and monitoring identity can prevent financial harm to aging parents.
A study analyzing 500,000 customer service interactions shows chatbots struggle with complex issues while human agents excel at matching customer communication styles.
Aigen's Element robot uses solar power and AI to provide farmers with a sustainable alternative to herbicides, working efficiently in cotton and soy fields.

Microsoft CRM or Siebel

Siebel is traditional CRM market leader, however and mostly due... Read More

Crystal Reports - Geterogeneus databases: SQL Server, Oracle, Unidata, Btrieve ? Tips For Developer

Crystal Reports is the most flexible tool on the market... Read More

Microsoft Great Plains Chemicals & Paint Industry Implementation & Customization Notes

Microsoft Great Plains fits to majority of industries, in the... Read More

New Web-Based HR Tool is Max From NAS, Hannibal, and InfoLink

Three highly respected names in Human Resources have joined forces... Read More

5 Easy File Management Tips in Microsoft Word

How many steps does it take you to locate and... Read More

How to Upgrade Dexterity Customization ? Tips for IT Manager

If you have Microsoft Great Plains and support it... Read More

Introduction To ISDN, Part II

In the previous ISDN article, we looked at how and... Read More

Microsoft Great Plains Customization Tools ? Overview

Former Great Plains Software Dynamics/eEnterprise, and currently Microsoft Business Solutions... Read More

Accessing XML Using Java Technologies

The most important benefit of XML is its simplicity. Though... Read More

Crystal Reports - Microsoft SQL Server

Microsoft SQL Server is the leader for inexpensive and middle... Read More

Troubleshoot Windows with Task Manager

Task Manager is a Windows system utility that displays thetasks... Read More

5 Mac Security Tips You Can?t Live Without

So, you've bought a new Macintosh, and now you may... Read More

The Dirt on Screensavers

Remember back in the days where screensavers were the coolest... Read More

Microsoft RMS ? Great Plains Integration ? Overview For IT Specialist

Microsoft Great Plains and Microsoft Retail Management System (Microsoft RMS)... Read More

The Bluebird Project

The objective for Zandi Digital is to make available clever... Read More

Windows Screensavers Explained

In this article you will find some background information about... Read More

Microsoft Great Plains Food Processing ? Implementation & Customization Highlights

Microsoft Great Plains might be considered as ERP platform to... Read More

Microsoft Great Plains Multicurrency ? Overview For Implementation Consultant

When you first think about multicurrency ? you probably have... Read More

Software Upgrades Arent Always the Best Move

When my daughter was getting into AOL instant messaging (AIM)... Read More

Alien Intruders!

You probably didn't casually invite, or extend a formal attendance... Read More

Microsoft Great Plains Security Setup - Overview For Consultant

Microsoft Business Solutions Great Plains is very good fit for... Read More

PHP On-The-Fly!

IntroductionPHP can be used for a lot of different things,... Read More

Microsoft Axapta, Navision or Great Plains: ERP Selection for Large Corporation

If you would like to pick something from Microsoft, or... Read More

Kick-Ass Performance For Your PC? Its Easy

Is your PC is slow and wimpy? Then you need... Read More

Spyware Protection: A Must for Any Home Computer

Now that spyware is the single most dangerous threat to... Read More

green cleaning service Park Ridge ..