[Qt-interest] Scroll Fetching with QSortFilterProxyModel
Scott Aron Bloom
Scott.Bloom at onshorecs.com
Tue Aug 31 05:27:50 CEST 2010
I think you would be much much better off to add the WHERE clause to the
original SQL...
I cant think of any other way to do it using a proxy filter...
Scott
-----Original Message-----
From: qt-interest-bounces at trolltech.com
[mailto:qt-interest-bounces at trolltech.com] On Behalf Of Willy P
Sent: Monday, August 30, 2010 4:21 PM
To: Willy P
Subject: [Qt-interest] Scroll Fetching with QSortFilterProxyModel
Hey,
I have a QSqlQueryModel attached to and SQLite DB that produces a
large result. Between it and the view, I have a QSortFilterProxy
model that dramatically reduces the output.
[BIG QUERY] -> [FILTER] -> [VIEW]
As I scroll in the view, it loads more data on the fly. I really like
this behavior. But my question is this:
If the view is mostly empty BUT there are valid results that are not
yet fetched, how can I get the view to "demand more."
I don't want to use:
while( model->canFetchMore() ) { model->fetchMore(); }
B/c it actually reads the data into memory.
The "scroll fetching" seems to just seek ahead in the query until it
gets a hit. How can I tell the model to keep seeking for more hits
w/o reading the results of the entire query into RAM?
I appreciate any advice you have...
Thanks...
-Willy
_______________________________________________
Qt-interest mailing list
Qt-interest at trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-interest
More information about the Qt-interest-old
mailing list