PixivUtil2
PixivUtil2 copied to clipboard
Replace root does not seems to work on huge sqlite db
I moved my collection to another path this week end. When I try to replace the root path, a sqlite-journal is created and the cli exit it states (return to db menu), but the journal does not disapear and no change is done to the db (verified with sqlitebrowser). I waited around one hour and nothing seems to happen.
The db is ~174MB.
After 1h30 I had some changes, it is just extremely slow. Edit: no it did not work after all. :(
fyi, it took 15879ms with this query:
UPDATE pixiv_master_image SET save_name = replace(save_name, 'I:\Pixiv', 'P:\Pixiv') WHERE save_name LIKE 'I:\Pixiv%'
And your code does exactly the same thing, so ... I dunno.
maybe because of python sqlite lib? I cannot do anything if this true...
@whinette
While testing update root, I found that the database is not committed until until the you exit the Manage Database menu. To be safe, try exiting the whole program normally after performing the update ( you will be prompted by menu again once it completes). This worked perfectly fine for me and I have >196,000 (43.1 MiB) entries.
If you are displaying your database in a GUI remember that you will have to refresh, because the records have changed in a transaction after the one initially used to display those results.
I haven't seen any changes to my DB when using it.
the output of this text is instant, so it doesn't seem like anything really happened either.