Author Topic: with a very huge amount of data, how you do?  (Read 3309 times)

fabiopesaju

  • Full Member
  • ***
  • Posts: 100
with a very huge amount of data, how you do?
« on: December 14, 2014, 06:46:51 pm »
with a very huge amount of data, how you do?

I mean ... someone already did with Lazarus, some kind of grid with 'pagination'?

like web, with 'go to page', 'start', 'previous', 'next', 'end', 'all', 'display xx per page'...

« Last Edit: December 15, 2014, 09:03:56 pm by fabiopesaju »

mangakissa

  • Hero Member
  • *****
  • Posts: 1131
Re: with a very huge amount of data, how you do?
« Reply #1 on: December 16, 2014, 09:02:22 am »
What doe you mean about a very huge amount of data.
A dataset can be controlled by fetching (just read records givven by you. By scrolling read another batch of records). A query can make your dataset as big as you want.
Lazarus 2.06 (64b) / FPC 3.0.4 / Windows 10
stucked on Delphi 10.3.1

marcov

  • Administrator
  • Hero Member
  • *
  • Posts: 12984
  • FPC developer.
Re: with a very huge amount of data, how you do?
« Reply #2 on: December 16, 2014, 10:46:07 am »
I guess he wants pagination like in websites.

One could just take a grid, and load it with a query parameterized with the relevant parameters.

But it depends on what exactly you want to do. Do you want to minimize number of queries, query sizes, or just gui ?

fabiopesaju

  • Full Member
  • ***
  • Posts: 100
Re: with a very huge amount of data, how you do?
« Reply #3 on: December 16, 2014, 12:31:43 pm »
What doe you mean about a very huge amount of data.
A dataset can be controlled by fetching (just read records givven by you. By scrolling read another batch of records). A query can make your dataset as big as you want.
I mean: a lot of users performing the same query ... resulting in large volumes of the same information.
yes, a query can make my dataset as big as i need/want...

I guess he wants pagination like in websites.

One could just take a grid, and load it with a query parameterized with the relevant parameters.

But it depends on what exactly you want to do. Do you want to minimize number of queries, query sizes, or just gui ?
exactly.
I want to do the same like in websites,
I want to minimize the size of results and make a nice gui.

marcov

  • Administrator
  • Hero Member
  • *
  • Posts: 12984
  • FPC developer.
Re: with a very huge amount of data, how you do?
« Reply #4 on: December 16, 2014, 03:09:20 pm »
I guess he wants pagination like in websites.

One could just take a grid, and load it with a query parameterized with the relevant parameters.

But it depends on what exactly you want to do. Do you want to minimize number of queries, query sizes, or just gui ?
exactly.
I want to do the same like in websites,
I want to minimize the size of results and make a nice gui.

Nice gui is subjective. The reason the web traditionally does that is because it pushes the whole query through each refresh. This is generally not the case for client GUIs, grids can manage quite large numbers,
and can additionally have (client side) filters etc.

But if you want to continue that way, the most sense would be to have an extra dataset (tbufdataset, memory dataset) (wired to the grid), and copy only the <x> tuples that you are interested in from the main query.


 

TinyPortal © 2005-2018