Hibernate Tutorial 25 - Introducing HQL and the Query Object

preview_player
Показать описание
Introducing HQL and using HQL to run queries on the database.
Рекомендации по теме
Комментарии
Автор

All these videos are 7 years old but are still very useful as they touch basics. Good work man keep it up!

pramodar
Автор

You should allow us to support you with $$. Great videos and teaching style. Thanks a lot!

ramreddy
Автор

Keep doing the good work Koushik ..Learnt a lot, seriously a lot from you tutorials.

waiting for REST tutorials :)

avinashreddy
Автор

...Koushks is doing a great job, I appreciate what you are doing man, keep them coming, thanks alot!

mercygachokawairimu
Автор

your tutorials are easy to follow and understand, Thanks...

itsagame
Автор

Excellent videos koushik....keep t upppp

aar
Автор

superb teaching..learnt lot of things from these videos thanks a lot

sudhaangadi
Автор

Great work and great tutorial... Thanks a lot for uploading it to YouTube.. Keep up with the awesome work.

SushilShah
Автор

Hi koushik, can you please update any video on hql union and order by

SureshKumar-usdh
Автор

Great videos, great job, learning a lot. Thanks

Faraz
Автор

Just to make sure you did everything correct :

1) Check your database you have data inside your UserDetails table.
2) Before running HQL, make sure you change your configuration "hbm2ddl.auto" from "create" to "update".
3) Then try again. If not working step back to the first step :)

Because there is no reason not to fetch data from database in this simple example.

kerimaliyilmaz
Автор

Can I get all the records from database without using primary key in where clause using hibernate?

debabratalenka
Автор

Very nice video but I would have liked to see the "users" object as well has how to work with it

afifkhaja
Автор

in cse of annotaion name given to table and column so what happends in hql

kamranrahmatullah
Автор

Hi Kaushik, I have an sql in which I apply a join in result of a subquery and a separate table, eg.

Select * from student_fees fees join (select max(I'd), section from student where I'd =1 group by section) as std on std.id = fees.id .

I want something like this in hql. Here I am fetching the last student of each section and making join with feel table. Please let me know if hql with same purpose can be created.

Also I do not need an 'in' clause because that breaks with more than 1k records.

mayankvaid
Автор

Query is deprecated now, does anybody knows the alternative?

imdadabro
Автор

Dont import QUERY from “org.hibernate” (as its Deprecated now). Instead import from “org.hibernate.query” .

aniwar
Автор

Great tutorial series Koushik. One question regarding this tutorial and HQL: I believe the main reason behind using an ORM framework like Hibernate was to avoid writing database queries. I get that with HQL we are not writing exact SQL queries and its somewhat object-oriented but essentially we are doing the same thing as passing SQL queries through JDBC but in a slightly different syntax. Doesn't this defeat the major purpose of using Hibernate?

namanmishra
Автор

Hi, your tutorial is great, thank you very very much.
I have a question: The session.createQuery("from UserDetails") returns me no results!
And i did the same what u did in the tutorial. I googled but i couldnt find the problem.
Can u help me to continue the next parts of the tutorial please?
Thank u so much

kachalkhan
Автор

Sir, you haven't explained the reason for org.hibernate import instead of JPA.

mayurd