[Digikam-devel] [digikam] [Bug 339607] MYSQL : Images not show if corresponding ImageInformation entry does not exist in database

Richard Mortimer via KDE Bugzilla bugzilla_noreply at kde.org
Tue Jul 26 09:49:27 BST 2016


https://bugs.kde.org/show_bug.cgi?id=339607

--- Comment #6 from Richard Mortimer <richm+kde at oldelvet.org.uk> ---
Sorry. Had missed this one.

I cannot see an obvious reason why there would be a difference between SQLite
and MySQL. It should be easy to test the queries from the commandline in both
database types to see if they really do return different results.

The only possible theory that springs to mind would be related to the fact that
in getItemURLsInAlbumByItemDate and getItemURLsInAlbumByItemRating the
ImageInformation.rating order by field is not included in the selected columns.
I know that some databases (PostgresQL for instance) are very strict about that
but MySQL and SQLite tend to be much looser in enforcing that type of SQL
behaviour.

Whatever of the cause I would certainly be in favour of Swati's suggestion of
using a LEFT JOIN instead of an INNER JOIN in the 5 queries that are
referencing ImageInformation within them. Of course the calling code would need
auditing to ensure that it could cope with those fields having null values if
the ImageInformation row is not present.

-- 
You are receiving this mail because:
You are the assignee for the bug.



More information about the Digikam-devel mailing list