This object is in archive! 
Performance when deleting track points...
Closed
... is abysmal. It takes 10(!) seconds to delete a point from a 5000-point-track (Galaxy Note 2). What kind of horrible database package is this? Doesnt Android offer something a little more reasonable? As this is a user interface operation, I expect it to be instantaneous.
With this delay, I find it impossible to correct tracks with a bunch of misplaced points. Like when you enter a building or some such.
Hello joeloc,
this happen to you with every single point on such longer track? Wasn't it just one time issue?
Do you have your database on SD card or in internal memory? (I'm asking as internal memory is usually a lot faster). Also what about database size? Didn't you though about archiving (and later removing) older tracks from your database, to reduce it's size? Well, 10 s is way to much, completely agree.
Hello joeloc,
this happen to you with every single point on such longer track? Wasn't it just one time issue?
Do you have your database on SD card or in internal memory? (I'm asking as internal memory is usually a lot faster). Also what about database size? Didn't you though about archiving (and later removing) older tracks from your database, to reduce it's size? Well, 10 s is way to much, completely agree.
Fine, testing ...
I've duplicated some tracks in my database and now I have 260 MB big file almost 3 mil points. Deleting single point took me around 5 seconds now.
Test (measuring) shows, that almost 100% of time is consumed by direct SQL query to delete single line with certain ID (delete trackpoint) and change index of previous trackpoint (change one ID). I've tried to add new index over one column, but it speed up a process to around 3 seconds, but increased size of DB by extra 40 MB.
Hard to say. I'm not an database expert, but for me it looks like limit of SQLite database on Android.
Fine, testing ...
I've duplicated some tracks in my database and now I have 260 MB big file almost 3 mil points. Deleting single point took me around 5 seconds now.
Test (measuring) shows, that almost 100% of time is consumed by direct SQL query to delete single line with certain ID (delete trackpoint) and change index of previous trackpoint (change one ID). I've tried to add new index over one column, but it speed up a process to around 3 seconds, but increased size of DB by extra 40 MB.
Hard to say. I'm not an database expert, but for me it looks like limit of SQLite database on Android.
Good evening joeloc,
old topic. Not sure if some performance improvement happens on your side (maybe opposite with increased database side).
I'm closing this topic. The database structure that was made for storing tracks is not optimized for this task and with my skills, I was unable to get more from it. We think about the update of the database to the different format, so maybe it will be automatically solved during this process. We will see.
Menion
Good evening joeloc,
old topic. Not sure if some performance improvement happens on your side (maybe opposite with increased database side).
I'm closing this topic. The database structure that was made for storing tracks is not optimized for this task and with my skills, I was unable to get more from it. We think about the update of the database to the different format, so maybe it will be automatically solved during this process. We will see.
Menion
Replies have been locked on this page!