Hello All programmers I just developed a small HQL to SQL Convertor. Valuable suggestions are welcomed and appreciated [] http://infosyndrome.blogspot.com/2009/11/hql-to-sql-convertor.html
You can just add the following option to your config file: <property name="hibernate. show.sql" value="true"></property> And SQL will be displayed in log file.
Yes there is an Option But for that u need to create a Session and other things.. You need a Hibernate.conf.xml and the mapping files of the Classes and objects u using in that Here u dont need any thing connection Just input a query , the equivalent SQL query is returned
Anyway, you can get all necessary code from Hibernate shources. You don't need to write such converter by yourself. All work is already done by Hibernate developers.