I am using createSQLQuery with setString (without a hard coded value) in Hibernate. I want to know that Hibernate uses PreparedStatement for createSQLQuery ?
Concern:
I want to save the execution plan created by this request in the cache the next time the same request is launched in the database. He will use the same execution plan.
FYI: I am using MSSQL Server 2008
Query nativeSQLQuery = session.createSQLQuery("select Firstname from user_master where user_name = :param"); nativeSQLQuery.setString("param", "vicky.thakor");
I could not find a link to stackoverflow or even google, so please provide me a link if one is.
java sql sql-server hibernate
Vicky thakor
source share