question

RiteshSingh-7541 avatar image
0 Votes"
RiteshSingh-7541 asked JarvanZhang-MSFT edited

SQLite corrupt exception in Xamarin iOS app using HybridWebView

In our iOS application, we have provided the data Downloading feature from the API. Here we first delete the data from the local SQLite database and then insert the newly fetched data from the API into SQLite DB. ​
It works fine for the 1st and 2nd time when we install the app on an iOS device. But after that, if we try to download the data for 3rd time then we get a "database disk image is malformed" error.

The application works fine on Android devices but it is not working in iOS.



dotnet-xamarindotnet-sqlite
· 4
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Hi, @RiteshSingh-7541 Could the sqlite database work if re-deploying the project on the ios device? And will the issue occur every time when downloading the data for 3rd time? Make sure that only one thread is trying to write to the database at a time.

1 Vote 1 ·

Could the sqlite database work if re-deploying the project on the ios device?

Yes, If we re-installed the app, it is working fine for 1st and 2nd time but for the 3rd time getting the same issue.

0 Votes 0 ·

And will the issue occur every time when downloading the data for 3rd time?

The app is no longer accessible once get the error. I have to re-install it every time after the error.

0 Votes 0 ·

Is the function achieved on each platform or on the shared project? Do you use the background process on iOS? Please post the related function code, it'll help to get the cause to the problem.

0 Votes 0 ·

0 Answers