Tuesday, 14 January 2014
Do you like this Article?
ORM (Object Relational Mapping) is a programming concept of a mapping between Object Oriented Programming and Relational Database. It’s the technique to frame the components of Relational Database to Object Oriented Programming, to do CRUD operations. It creates an object oriented representation of a relational database, so that developers can push or pop data to database as an object.
Databases are designed on the basis of Mathematical principle where as programming languages like Java, C++, C# are based on Object Oriented Programming principle. Objects have behavior and attribute, it’s good on business modeling where on the other hand database is only deals with large amount of data. Now due to this conceptual deference, in real life scenario, database transactions become unmanageable, when we are dealing with large amount of data transaction. So to bridge this difference, ORM is introduced. It’s the process of mapping tables to class objects, so that data transactions could be easier.
- Create classes replicating database tables, in programming language side, so that programs can interacts with objects not direct tables.
- Provides APIs for normal CRUD (Create Read Update Delete) operations, so no need to write queries for that.
- Some provides query language which is database independent.
- Provision to interact with multiple databases.
- Helps to manage business logic easily when dealing with big amount of data, and lots of database transaction.
- No need to use when your application doesn't involve much database interaction.
- Little bit heavier than native database connectivity.