How to delete all data in Local DB?

Hi everyone, how can i delete all data in my Local DB, from row 1 to the length of the list? can anyone show me a sample blocks? please… first i was thinking it was because of cache, but it was stored in the LOCAL DB, and i want to update i from time to time, by deleting old data then after user click a “store” it will load another “data”

1 Like

Hi,

You can’t delete rows, but you can write an empty string to all cells (or some other character that will indicate that there is no data)

1 Like

Screenshot_2020-06-14 Thunkable
but there’s a block here that say “delete row”, then i dont delete row, also each data duplicate, is it a bugs? or do you have any recommended way of blocking for deleting all data in Local DB then how to write data to Local DB using list,

“row id” is a row ID, not an ordinal number, as you and some other users believe.

LocalDB blocks

изображение

You are not using Local DB, but Data Source, which actually has a block for deleting a row by its ID.

im very sorry as im really new in thunkable, im sorry it was the LocalDB in the “data sources” that im using in data listview where i load all data hereScreenshot_2020-06-14 Thunkable(1)
after that remove all data again so i can add new datas like refreshing it and show in data listview

Using the delete block, you can delete only those rows that you created using the create block and then saved the row id somewhere else

1 Like

Hi @actech,
in my opinion there should be a way to iterate over the entries of a data source. That way I could reuse the information that is stored in the data source or search for entries. Right now we can choose with a data list viewer, but I am missing a way to search through the data source.

1 Like

Hi,

If you think there is such a way, can you show it to me? I’m always happy to find out what I don’t know.

can you show please, by creating a data in a data sources using localdb then delete all data by row, i will appreciate it so much, as my way is not working (image above)

The DataSource is a raw, very slow, and insufficiently functional component. For this reason, I don’t want to waste time working with him. I prefer to ride a work bike rather than a motorcycle that will be repaired in a few months. I think you understand me.

3 Likes

Hi @actech,

yes, the data source is indeed very slow. It could be a good alternative to the local db, but there lack several features, like iterating. The only reason to work with it are the nice data list viewers, which look prettier than the standard list view.

I’m afraid that iPhone and Smartfone users will not be able to work with lists . If the beautiful list is slow, the user will swear and throw the app in the trash. If the list works fast but looks ugly, the user will swear and throw this app in the trash, too.

1 Like