I have been looking at the debug log when I am tagging, via drag drop (onto a MagicNode)
I see this statement multiple times:
[6020] 6224 DB open SQL: SELECT NULL FROM Songs WHERE Songs.IDFolder in (SELECT IDChildFolder FROM FoldersHier WHERE IDFolder=3) LIMIT 1
[6020] 6224 DB lock finished, took 16296.
This would be about 10 times quicker (run using SQLViewer):
[6020] 6224 DB open SQL: SELECT NULL FROM Songs s INNER JOIN FoldersHier fh ON s.IDFolder = fh.IDChildFolder WHERE fh.IDFolder=3 LIMIT 1
[6020] 6224 DB lock finished, took 1251.
I know it won't solve the slow tagging, but every little but helps.
I would also question, why it is running the same query over and over.
I also see a huge number of these statements:
[6020] 6224 DB open SQL: SELECT ID,TrackCount FROM Folders WHERE IDMedia=? AND IDParentFolder=? AND Folder=?
[6020] 6224 DB lock finished, took 51.
Just wonder what these are all doing. Wonder if they are all required (obviously I don't know what the ? are, so can't tell if they are duplicates)
[1452] Tagging performance - Improved SQL Query [#8626]
Moderator: Gurus
Re: [1452] Tagging performance - Improved SQL Query
Hi, added the first issue to be reviewed as http://www.ventismedia.com/mantis/view.php?id=8626.
Thanks,
Jiri
Thanks,
Jiri