Working with Large Data Tables

What I’m trying to do:
I would like to plot from large data tabels.

My question is what approach would be best?

  1. query each time I need data from client form.
  2. pull the data table in the client form and work with it there.
  3. pull the data table in the server module and feed data to the client.

My current method is pulling data into the server and feeding to the client, but it seems to make the form really slow to load.

I have been using the time.time() to time each method above, but they all seem to give around the same time.

What is the proper way to do this in Anvil??

In programming, there’s almost always more than one way to do anything. Try searching the forum for “performance”. You’ll find lots of hints, some of which will likely apply in your situation.

If you want someone here to take a closer look, then they should have some details to look at: your pattern of data access, and a description of the structure of the table(s) involved. Otherwise, it’s all guesswork, from our end.

2 Likes

Thank you for pointing me in the right direction. Searching for ‘performance’ yielded good reading material.

1 Like