Object Relational Mapping (ORM) by R4R Team

ORM stands for Object-Relational Mapping (ORM) is a programming technique for converting data between relational databases and object oriented programming languages such as Java, C# etc. 

First problem, when we need to modify the design of  database after having developed few pages or our application? 

Second, Loading and storing objects in a relational database. So here below some basic mismatch and their description are given:

Mismatch

Description

Granularity

Sometimes you will have an object model which has more classes than the number of corresponding tables in the database.

Inheritance

RDBMSs do not define anything similar to Inheritance which is a natural paradigm

in object-oriented programming languages.

Identity

A RDBMS defines exactly one notion of 'sameness': the primary key. Java,

however, defines both object identity (a==b) and object equality (a.equals(b)).

Associations

Object-oriented languages represent associations using object references where

as am RDBMS represents an association as a foreign key column.

Navigation

The ways you access objects in Java and in a RDBMS are fundamentally different.


The Object-Relational Mapping (ORM) is the solution to handle all the above impedance mismatches.


Leave a Comment:
Search
Categories
R4R Team
R4Rin Top Tutorials are Core Java,Hibernate ,Spring,Sturts.The content on R4R.in website is done by expert team not only with the help of books but along with the strong professional knowledge in all context like coding,designing, marketing,etc!