Is it Mandatory to map each pojo class variable with table
column in Hibernate? Is there any alternative to skip some
of those? Thanks in advance...

Answers were Sorted based on User's Feedback



Is it Mandatory to map each pojo class variable with table column in Hibernate? Is there any altern..

Answer / simhanijagadeesh

good question...good question...we need all colunns
properties map in pojo.hbm.xml and pojo when and only we
need to create with that table creation.if you are doing
fetching data no need of all variables in pojo and hbm
file.good Question by you.....keep it up...I tested and
found in my real project...I will give you clear info on
this after verifying my project.

Is This Answer Correct ?    0 Yes 0 No

Is it Mandatory to map each pojo class variable with table column in Hibernate? Is there any altern..

Answer / shashi

No,its not mandatory to map each variable in class with table column in hibernate.

you can skip some of the those using trasient keyword from persisting into database

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Java J2EE AllOther Interview Questions

Which interface does java.util.hashtable implement?

0 Answers  


What are maps interfaces in the java collections? : java collections

0 Answers  


Write a interface "CarOperations" with the following methods void turnOnEngin() void turnOffEngin() void turnOnLigths() void turnOffLights() void turnLeft() void turnRight() void accelerate() void deaccelerate() void putBreaks() void releaseBreaks()

1 Answers  


my interviewer asked me what technical specification you used how to answer that question

0 Answers  


How many controlers are there in spring? Plz send me ans

1 Answers   HCL,






When to use the Collection Classes(HashSet, LinkedHashSet, TreeSet....etc) in real time scenario ?

1 Answers   Cap Gemini,


What is the enumerator of the java collection framework? : java collections

0 Answers  


What is IOC in spring?

10 Answers   Centris,


What is an algorithm in java collection framework? : java collections

0 Answers  


what debugging tool that can be used to debug the java programs?

1 Answers   Inforica,


What is the servletcontext listener and what is JspContext and page context pls tell in simple words.

1 Answers   IBM,


whatis arguments &what is default argument

2 Answers   CTS,


Categories