Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.java.databases > #177

Hibernate question/Classe

Path csiph.com!x330-a1.tempe.blueboxinc.net!feeder1.hal-mli.net!news.glorb.com!news-out.readnews.com!news-xxxfer.readnews.com!news-out.news.tds.net!newsreading01.news.tds.net!86597e80!not-for-mail
From "Tobi" <tobi@THRWHITE.remove-dii-this>
Subject Hibernate question/Classe
Message-ID <927be799-bcef-446a-805d-85e54a22588b@f63g2000hsf.googlegroups.com> (permalink)
X-Comment-To comp.lang.java.databases
Newsgroups comp.lang.java.databases
Content-Type text/plain; charset=IBM437
Content-Transfer-Encoding 8bit
X-Gateway time.synchro.net [Synchronet 3.15a-Win32 NewsLink 1.92]
Lines 22
Date Wed, 27 Apr 2011 15:22:12 GMT
NNTP-Posting-Host 96.60.20.240
X-Complaints-To news@tds.net
X-Trace newsreading01.news.tds.net 1303917732 96.60.20.240 (Wed, 27 Apr 2011 10:22:12 CDT)
NNTP-Posting-Date Wed, 27 Apr 2011 10:22:12 CDT
Organization TDS.net
Xref x330-a1.tempe.blueboxinc.net comp.lang.java.databases:177

Show key headers only | View raw


  To: comp.lang.java.databases
Hi-

I have two hibernate classes, with a many to one relationship existing
between them.  The first class, Task, contains a set of Listener
objects.

I am able to save Task objects and have the set of Listeners also save
properly.  Am wondering how to do a query for only Task objects that
have a non-empty Listener set.  I used the Restrictions.isNotEmpty()
on the listener property, but it seems to be returning all of the Task
objects, instead of just Task objects where the collection isn't
empty.

Are there any gotchas I should look out for?

Thanks

---
 * Synchronet * The Whitehouse BBS --- whitehouse.hulds.com --- check it out free usenet!
--- Synchronet 3.15a-Win32 NewsLink 1.92
Time Warp of the Future BBS - telnet://time.synchro.net:24

Back to comp.lang.java.databases | Previous | Next | Find similar


Thread

Hibernate question/Classe "Tobi" <tobi@THRWHITE.remove-dii-this> - 2011-04-27 15:22 +0000

csiph-web