Bug in Spatialite-gui 2.0.0-devel

21 views
Skip to first unread message

Roberto Angeletti

unread,
Jul 7, 2015, 4:50:46 AM7/7/15
to spatiali...@googlegroups.com
Alessandro,


the number of rows  reported  in query between [ ]  output  is wrong.

:(


Ciao

Roberto

a.fu...@lqt.it

unread,
Jul 7, 2015, 5:30:08 AM7/7/15
to spatiali...@googlegroups.com
On Tue, 7 Jul 2015 10:50:44 +0200, Roberto Angeletti wrote:
> Alessandro,
>
> the number of rows  reported  in query between [ ]  output  is
> wrong.
>
> :(
>

ciao Roberto,

it's not wrong; is the interpretation that has now changed.

historical behavior
-------------------
- max 500 rows from the ResultSet were displayed at each time
- and the rows count on the bottom was always correctly set so
to correspond to the total number of rows in the ResultSet.

this had a very bad impact on queries returning an huge ResultSet
containing perhaps one million rows or even more, simply because
the whole ResultSet required to be fully scanned from start to end
in order to exactly determine the total rows count.
this could easily be a very lengthy operation (requiring many
seconds, or may be many tenth seconds) while querying some huge
dataset, and several users asked for implementing a smarter/faster
solution.


new behavior adopted by 2.0
---------------------------
- still continuing to display max 500 rows at each time
- anyway the loop scanning the ResultSet now stops immediately
after retrieving the last row to be displayed on the screen.
this ensures a noticeable performance boost while processing
huge ResultSets but completely forbids to know in advance the
exact number of rows contained into the ResultSet.

so in 2.0 the figure shown on the bottom cannot be longer assumed
to represent the total number of rows contained into the ResultSet;
now it simply corresponds to the maximum number of rows being
effectively displayed on the screen since now.

useful trick:
--------------
you simply have to click the navigation button
"ResultSet: Go To Last Row"

this will force to completely read the ResultSet from start to end,
and will definitely set the "genuine" max row count.

bye Sandro
Reply all
Reply to author
Forward
0 new messages