Diese Seite mit anderen teilen ...

Informationen zum Thema:
Forum:
WinDev Forum
Beiträge im Thema:
7
Erster Beitrag:
vor 4 Jahren, 4 Monaten
Letzter Beitrag:
vor 4 Jahren, 4 Monaten
Beteiligte Autoren:
Ericus, Fabrice Harari, Piet van Zanten, Allard

[WB17]Table Display of Data

Startbeitrag von Ericus am 17.09.2013 09:33

Hi

I have a table in Webdev displaying data coming from an embedded query. The query returns about 7000 records.

Displaying this in the table takes a bit long.

Does anybody have a tip or two on how to rewrite the process so that the table is at least showing some data immediately as it gets filled with the rest of the records?

Thanks in advance.



Ericus Steyn

Antworten:

Hi , Is it an Ajax table or not

If you use a "Normal"table you can put say 40 records and add a pager to the table. I think this is a bit faster

regards

allard

von Allard - am 17.09.2013 11:54
Thanks Allard

It is an Ajax Table so that the user can search on Code or Description or sort the columns. Although with the amount of records it is a bit slow to refresh.

I was thinking maybe there is a way to run the query and then run a thread to populate the table with, let's say a 100 records at a time so the user see the first 100 immediately and is then not aware that the table is still being populated with more records.

Any other ideas please?


Ericus Steyn

von Ericus - am 17.09.2013 12:40
Hi Ericus

I haven't tried this technique in webdev, but this is how I would try it:
- run the query in server code
- add 100 lines to the table (still in the same server code)
- end server code sth tabledisplay

- on the browser side, add a timer. In the procedre called by timer do an executeprocess (clicl) of a hidden button
- in the button, server code is in ajax mode, add 100 more records to the table, do (or NOT, to be tested) a tabledisplay)

Let us know of it works

Best regards

von Fabrice Harari - am 17.09.2013 12:52
Thanks Fabrice

Yes it works sort of. When the timer executes to fetch an additional 100 records the data in the table disappears for the two seconds it takes to get the new records.

So it is disruptive on the eyes for the 2.5 minutes it takes to load the data.

I might have to rethink what to do because with that amount of data you cannot work with the table at all i.e. sort on the columns or find a specific item, as it takes to long.

Thanks in any case.


Ericus Steyn

von Ericus - am 17.09.2013 15:34
Hi Ericus

I was afraid of something like that would happen, as I wasn't sure that the ajax system was mart enough to ONLY send the new data and add it to the table...

Now, about :

Quote
Ericus
I might have to rethink what to do because with that amount of data you cannot work with the table at all i.e. sort on the columns or find a specific item, as it takes to long.


I compltely agree... I do not see ANY circumstance where I would find acceptable to load 7000 records in a table... Clealry NO USER is going to read 7000 lines :-)

Best regards

von Fabrice Harari - am 17.09.2013 20:30
Hi Ericus,

Did you use loaded in memory or direct access for the data source?
Direct access might be the solution, except that you can only sort and search on columns that are indexed in the file.

Regards,
Piet

von Piet van Zanten - am 18.09.2013 06:07
Zur Information:
MySnip.de hat keinen Einfluss auf die Inhalte der Beiträge. Bitte kontaktieren Sie den Administrator des Forums bei Problemen oder Löschforderungen über die Kontaktseite.
Falls die Kontaktaufnahme mit dem Administrator des Forums fehlschlägt, kontaktieren Sie uns bitte über die in unserem Impressum angegebenen Daten.