I mentioned the lightweight OODB db4o in some earlier blog entries and I admit that I really like that piece of software.
For that, I like to guide your attention to another blog, giving a nice overview about the various approaches for queries, esp. the native queries introduced with db4o V5.0. I feel it is worth reading.