Chapter 11.3. Smart Queries

So, perhaps you want to have the benefits of SQLObject without losing the flexibility to create complex queries against your database. Fortunately, the makers of SQLObject thought this, too, so they provide a couple of mechanisms that make it possible to create complex queries without the need to drop down to queryAll.

You’ve already seen a glimpse of how easy it is to query the DB using SQLObject select() and selectBy() methods. In this chapter, you’ll see how to get the maximum out of your DB while still reaping the benefits of SQLObject. As always, there is a subtle balancing act between ease of use, level of control, and performance. Some object relational mappers (ORM) trap you into specific uses and prevent ...

Get Rapid Web Applications with TurboGears: Using Python to Create Ajax-Powered Sites now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.