Forums Register Login

HQL problem

+Pie Number of slices to send: Send


is this example HQL is rom Insurance insurance.
my problem is it is leagel or not?
there is no select part?
+Pie Number of slices to send: Send
It is legal HQL query "from Insurance insurance"

if you configure show_sql to true in hibernate.cfg.xml, you can see a SQL query on console fired by Hibernate with all the properties in the Insurance class.

if you want only specific properties (columns) you need to use the "select.." clause.
+Pie Number of slices to send: Send
Just so you don't experience too much confusion, I would strongly recommend not using the roseindia tutorials. We see numerous questions here arising from buggy examples coming from that source. The best place to find out about HQL is the Hibernate documentation. If you have not already done this I would take some time to read it.
That's a very big dog. I think I want to go home now and hug this tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com


reply
reply
This thread has been viewed 976 times.
Similar Threads
Delete Query in hibernate doesnt work
Delete Query problem: Failure to Commit HQL Delete Transaction
what jar file need to run query.executeUpdate()
Hql delete syntax?
query.list gives null
More...

All times above are in ranch (not your local) time.
The current ranch time is
Apr 16, 2024 00:55:11.