Hibernate and Hibernate Query Language (HQL) Tutorial

ckeene's picture

We have created a powerful sample application in WaveMaker that provides an introduction to Hibernate Queries. In the application, each Hibernate query concept is described (inner join, outer join, group by, etc) and then you can test it out and see the results displayed live.

Hibernate Query Tutorial

 

The Hibernate Tutorial Application is here: http://demo.wavemaker.com/HQL_Guru/

The application itself is attached to this post. If you get inspired, create a few HQL queries of your own and submit them back to the community!

There is also a detailed Hibernate Tutorial on the Wavemaker Wiki.

Finally, the wiki also has a white paper we wrote on using WaveMaker as a tool for Java developers to automate the tedious process of Hibernate mapping.

 

 

AttachmentSize
HQLguru.zip65.63 KB

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Outside JOIN Queries example missing

Hi,

The Hibernate tutorial is very good but I notice it is missing example for Outside JOIN Queries. I am stuck trying to do an outer join and would a project example. Thanks.

some util hql queries

Thanks mavirroco,

Firstly, I don't speak spanish. I used google to translated the pages but I do not see any examples of OUTER JOIN

dille4's picture

HQL Joins

The best reference site for HQL:

http://docs.jboss.org/hibernate/stable/core/reference/en/html/queryhql-joins.html

 

 

Cheers, Tom _____________________________________________________________________________ Custom Widgets – Endless possibilities …

Cheers,

------------------------------------
Tom,

http://tinyurl.com/dittmarconsulting
------------------------------------

I don't get it

I don't see where the HQL is used in this example. All but one of the tabs is information for how to generate HQL but the one table/view appears to use a standard live view. I see a number of service variables that reference the HQL objects but I don't see any place they are used either.

elramirez's picture

Hi Ed, which particular

Hi Ed,

which particular example you been working with?

Does anyone know how to

Does anyone know how to limit the number of results in the query in my application

This can be done in the studio query editor with the "Max Results" box so it should also be possible in the application.

Thanks, Bill

 

elramirez's picture

Hi Bill, I do know it has

Hi Bill,

I do know it has been requested.

  WM-711

I'll add your interest as comments and keep the thread updated also If I reach a workaround in the meantime. If the svc var doesnt have it within it's unexposed functionality in it's code, maybe through a java service? hmm..

It would be good to have the

It would be good to have the capability of limiting the number of results for those that work with large tables.

 

Help Demo Not Working....

Click on the link for the demo and it just loads. Any ideas on whats up?

: http://demo.wavemaker.com/HQL_Guru/

I downloaded HQLguru.zip and opened project. Went to a query and clicked on test and said no database???

What am I doing wrong.