I’m working on an app that has to show objects on a map. The objects could be filtered by the user and the total amount of rows in the table is about 6000. Cause of the limit of 100 rows per page I wrote a for loop for retrieving all the data requested by the user.
The table has 9 columns 2 of which are relations one to one, one with a geopoint and the other with another table. If a make a simple query (for example “power>100”) I get these results:
- With autoload only on geopoint and using single step retrieve for the other relation: ~5.5s per page
- Using single step retrieve on both geopoint and the other relation: ~4s per page
- Using single step retrieve only on geopoint: ~3s per page
- Using single step retrieve only on the other relation: ~1s per page
- Without retrieving relations: ~0.5s per page
Each page is about 50 kb including relations.
I need to retrieve the geopoints because I have to show the objects on a map but the query is too slow.
I’m thinking about moving the geopoints to the table as two column (latitude and longitude) to solve this problem, but I would like to know whether it is supposed to be so or there is a problem and how to solve it. I’m using backendless cloud service.
Thanks in advance