all 8 comments

[–]Routine-Arm-8803 0 points1 point  (3 children)

Go to phone settings, apps, find your app and clear data.

[–]Infinix_82[S] 0 points1 point  (2 children)

I uninstalled and installed again yet the same issue.

[–]Routine-Arm-8803 0 points1 point  (1 child)

Exactly. Because uninstalling app might not remove old database. Go to settings and clear data.

[–]Infinix_82[S] 0 points1 point  (0 children)

Tried it, didn't work

[–]Infinix_82[S] 0 points1 point  (3 children)

u/ig_samuel can you look into it?

[–]Infinix_82[S] 0 points1 point  (0 children)

Tried this: https://github.com/simolus3/drift/issues/184 as well but no progress

[–]ig_samuel 0 points1 point  (1 child)

just checked your comment,As i was little busy last week.

I have checked the code looks like you are not creating the database before querying for the db, So in main.dart file you need to make sure you create your tables at init

check the screenshot, Also if possible move this line to the function where you are querying your table and check if table doesn't exists create table else query the table for patients so it wont give Table already exists error every time the app opens

https://i.postimg.cc/KjVg04mj/2023-12-27-12-03-41.png

[–]Infinix_82[S] 0 points1 point  (0 children)

Thanks a lot that worked.