Thank you, that's what I've looking for.
In my case, I only fill details view for one record only, 30-40 columns,
it's fast enough with one-column queries too.
But I wonder if it's possible to override get method to temporary switch
def get(self, id):
self.lazyColumns = False
entity = Customer.get(id)
self.lazyColumns = True
2010. 06. 22, kedd keltezéssel 13.42-kor Oleg Broytman ezt írta:
> On Tue, Jun 22, 2010 at 11:20:39AM +0200, Imre Horvath wrote:
> > Is it possible to select only a few columns from a table?
> No, but you can lazily selects columns using lazyColumns=True; with this
> SQLObject doesn't initially draw any column, only id's; but when you touch a
> row and ask for a column SQLObject executes a specific one-row one-column
> SELECT query. If you are going to touch a million rows this lead to at least
> few millions queries; perhaps it'd be faster to select all columns at once,
> but YMMV.