Apply patch #95860 to store empty icon (image 0) as a NULL value with SQlite and Mysql Databases
digiKam treats image zero as a "not set" icon value. This breaks referential integrity in the database because image zero does not exist. Explicitly convert a value of zero into NULL when stored in the database. Ideally digiKam should use an explicit null (in QVariant?) placeholder for the no-icon case but currently no database stores an image zero by default so the existing practice works. Note that when reading from the database the toLongLong method of QVariant returns a zero when called against a null value so this means that no changes are required when reading null values in from the database. CCBUGS: 355831
parent
10ef991c
Please register or sign in to comment