A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Win a copy of
Android Security Essentials Live Lessons
this week in the
Object Relational Mapping
[Solved]Hibernate and unknown databases
Joined: May 05, 2010
Feb 10, 2011 10:29:15
Hello again my fellow ranchers, I'm back again with another question...
It's possible to hibernate to get info from a table without doing a mapping cause that table's structure is unknown to the developer? (without going back to use native SQL)
without going back to use native SQL=old fashioned
That's what I wanted to say.
Thanks for your quick reply.
Joined: Apr 14, 2004
Feb 10, 2011 13:06:59
No, the mapping needs to exist.You can use Hibernate tools to generate mappings files or aonnotated classes from a database but this isn't really something you could do at runtime.
You don't however need to use Hibernate or native SQL to get information about a table. you can get that from godd old fashioned JDBC.
subject: [Solved]Hibernate and unknown databases
Schema Export Unsuccesful
Creating a "stored procedure" with HIbernate
alternate Floor function in JPA
Hibernate Native SQL versus iBATIS
Why I can't run Web Start when my class using hibernate?
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2014