More pros: * arbitrary mapping to non-bean/rich classes.. you can request primitives or maps * mapping the same tables to multiple classes and vice versa * no assumptions about primary keys
In many cases you'll find you *can* do a lot of these things with Hibernate, but it's more of a question of "should" you do it with Hibernate. If you want an ORM, use Hibernate. If you want to write SQL and map the inputs and outputs, use iBATIS. Clinton On Wed, Aug 6, 2008 at 1:45 PM, Sundar Sankar <[EMAIL PROTECTED]> wrote: > Hi , > Hibernate and Ibatis comparison is like comparing apples and oranges. > Bothe serve different purposes. This is what I told folks at my company b4 > we decided to go in with Ibatis instead of Hibernate. > > Pros of Ibatis > =========== > 1. Stored procedure support is out of the world. > 2. Not pure ORM and query control is primarily in our hands. We dont have > to assume that the query would be generated in a particular way. > 3. Hibernate doesnt work great if the tables arent well normalized. > 4. Hibernate 2, had tonnes of memory issues when dealing with enterprise > databases. Am not sure if 3 has solved it. > 5. If we just wanna fetch 2 columns from a table having 25 columns, > Hibernate plays bad in those scenarios. > > Other people could have different views, but these are what made me win > over using ibatis in our project a year back. > > -Sundar > > > > > On Wed, Aug 6, 2008 at 12:30 PM, mule_user <[EMAIL PROTECTED]> wrote: > >> >> Will it be possible to provide some pros and cons for the questions below: >> 1. If I were to use Hibernate 3.2 with Native SQL in several places of the >> project (because the database is complex and I do not have control over it >> as a Java developer), am I better off using iBATIS instead? >> 2. Will it be possible to cpmpare and contrast (pros and cons) Hibernate >> 3.2 >> with Native SQL versus iBATIS? >> -- >> View this message in context: >> http://www.nabble.com/Hibernate-3.2-Native-SQL-versus-iBATIS-tp18857922p18857922.html >> Sent from the iBATIS - User - Java mailing list archive at Nabble.com. >> >> >