PDA

View Full Version : How many items can Treeview /Tableview holds ?



prasad_N
23rd June 2015, 12:52
Hi,

How many number of items (or how many row&columns ) can table/tree view accommodate.
I am about to deal with GB's of data in tree & table view, So I got a doubt that "is there any point where tree/table crashes after inserting certain number of items ? ".


Thanks.

yeye_olive
23rd June 2015, 13:22
If you get your design right, then the view lazily queries the model as needed and does not impose any practical limit on the number of elements it can display. I recall displaying ~ 1 million of rows and columns. At this point it becomes a UI problem, because the user cannot easily scroll using a scrollbar with a resolution of a few hundred pixels.

Make sure you set up the view so that it does not need to go over the whole model just to compute the scrollbar's size. For instance, if you use a QTreeView and all the items have the same height, then do not forget to call setUniformRowHeights(true).

prasad_N
23rd June 2015, 13:41
Is there any restriction in accommodating number of items when i do Lazy loading ?

I am planing to work with lazy loading. ex: I have nearly 1 crore of rows but at a time I will load and show <200 rows only, So if i follow this approach there wont be any problems right ??

I want to implement an application which should show any number of rows (on an avg: 1/2 crores of rows).

d_stranz
23rd June 2015, 16:19
Well, there's a new word for me:


A crore (/ˈkrɔər/; abbreviated cr) is a unit in the Indian numbering system equal to ten million (10,000,000; in scientific notation: 107), which is written in these regions as 1,00,00,000 with the local style of digit group separators.

As yeye_olive says, you want to avoid making your entire model load in order to calculate simple things, like the total number of rows.

This discussion might help. (http://goobbe.com/questions/4062108/using-large-record-set-with-qtableview-and-qabstracttablemodel-retrieve-visible-)

prasad_N
6th July 2015, 06:32
I have come across this bug(https://bugreports.qt.io/browse/QTBUG-28631) during explorations, So can't we handle more then 70 million rows in a view ??

I am working with 64-bit applications so how many rows can I handle in this case ?