1600 PMP mock questions 1400 CAPM mock questions 800 SCJP 6 mock questions 600 OCAJP 7 mock questions 590 OCPJP 7 mock questions 556 SCWCD 5 mock questions 500 OCEJWCD 6 mock questions pdfDownload (java,struts, hibernet etc)
 

Recent Questions

!!! Hibernate Frequently Asked Questions !!!

SQL Queries In Hibernate..

!!!Answer!!!- From Technical Expert

You may express a query in SQL, using createSQLQuery() and let Hibernate take care of the mapping from
result sets to objects. Note that you may at any time call session.connection() and use the JDBC Connection
directly. If you chose to use the Hibernate API, you must enclose SQL aliases in braces:
List cats = session.createSQLQuery(
"SELECT {cat.*} FROM CAT {cat} WHERE ROWNUM<10",
"cat",
Cat.class
).list();
List cats = session.createSQLQuery(
"SELECT {cat}.ID AS {cat.id}, {cat}.SEX AS {cat.sex}, " +
"{cat}.MATE AS {cat.mate}, {cat}.SUBCLASS AS {cat.class}, ... " +
"FROM CAT {cat} WHERE ROWNUM<10",
"cat",
Cat.class
).list()
SQL queries may contain named and positional parameters, just like Hibernate queries.

Answered By : null Replied Date : Dec 21 2013
Answer :


Answered By : null Replied Date : Oct 13 2013
Answer :


Answered By : null Replied Date : Feb 7 2014
Answer :


Answered By : null Replied Date : Feb 14 2014
Answer :


Answered By : null Replied Date : Apr 25 2014
Answer :


Answered By : null Replied Date : May 3 2014
Answer :


Answered By : null Replied Date : Jun 30 2014
Answer :


Answered By : null Replied Date : Jul 9 2014
Answer :


Answered By : null Replied Date : Nov 3 2014
Answer :


Answered By : null Replied Date : Jul 6 2015
Answer :


Answered By : null Replied Date : Feb 25 2016
Answer :


Answered By : null Replied Date : Mar 20 2016
Answer :


Answered By : null Replied Date : Apr 24 2016
Answer :


Answered By : null Replied Date : Oct 24 2016
Answer :


Answered By : null Replied Date : Jul 16 2017
Answer :


 

You can also contribute to this answer:

Your Name:
Answer:

 
Ask Question and get answer from Expert.
View Answers List from Expert.

Reviews and Comments


PMP, CAPM, PMI is a registered certification mark of the Project Management Institute, Inc

Copyright © www.techfaq360.com 2016


About US | Contact US | Privacy Policy | Terms and Conditions  | Website disclaimer  | Cancellation and Refund Policy  | Shipping & Delivery Policy