[digikam] [Bug 364131] New: Same picture with different file extensions: Database scan only finds one variant of the file.

classic Classic list List threaded Threaded
28 messages Options
12
Reply | Threaded
Open this post in threaded view
|

[digikam] [Bug 364131] New: Same picture with different file extensions: Database scan only finds one variant of the file.

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

            Bug ID: 364131
           Summary: Same picture with different file extensions: Database
                    scan only finds one variant of the file.
           Product: digikam
           Version: 5.0.0
          Platform: openSUSE RPMs
                OS: Linux
            Status: UNCONFIRMED
          Severity: normal
          Priority: NOR
         Component: Database
          Assignee: [hidden email]
          Reporter: [hidden email]

Digikam does not pick up the same picture if it is present twice in a folder,
one file with a lowercase and one file with an uppercase extension: Only one
variant will be displayed in the database.

This is the problem as it occurs in my use case. I have to look further (if I
find the time...), whether the problem is one of the following:

- the same file with the same content/metadata
- the same file name, only with a varying extension
- not only the extension, but the case of the filename itself
- MySQL-specific or also for SQLite (I use MySQL!)

Reproducible: Always

Steps to Reproduce:
1. Create a new folder.
2. Copy a picture in it. Name it pic.JPG.
3. Copy the same picture in the folder. Now name it pic.jpg

Actual Results:  
Digikam will only display pic.JPG. pic.jpg is missing.

Expected Results:  
pic.jpg and pic.JPG should be present.

MySQL-Backend

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[digikam] [Bug 364131] SCAN : same picture with different file extensions : database scan only finds one variant of the file.

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

[hidden email] changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
          Component|Database                    |Database-Mysql
            Summary|Same picture with different |SCAN : same picture with
                   |file extensions: Database   |different file extensions :
                   |scan only finds one variant |database scan only finds
                   |of the file.                |one variant of the file.
                 CC|                            |[hidden email]

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[digikam] [Bug 364131] SCAN : same picture with different file extensions : database scan only finds one variant of the file.

bugzilla_noreply
In reply to this post by bugzilla_noreply
https://bugs.kde.org/show_bug.cgi?id=364131

[hidden email] changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |[hidden email]

--- Comment #1 from [hidden email] ---
Bug still reproducible in digiKam Version5.0.0-Beta7

Steps to reproduce:
1) Create a new folder.
2) Add image nature.jpg
3) Add same image by name nature.JPG

1) Create a another new folder.
2) Add image nature.jpg
3) Add same image by name NATURE.jpg

In both the cases, two images with respective names are present in each folder
(in case of SQLite). But images aren't present with MySQL (both Internal and
Remote)

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[digikam] [Bug 364131] SCAN : same picture with different file extensions : database scan only finds one variant of the file.

bugzilla_noreply
In reply to this post by bugzilla_noreply
https://bugs.kde.org/show_bug.cgi?id=364131

--- Comment #2 from [hidden email] ---
The "case-sensitivity" is by default in SQLite, and not in MySQL
( http://dev.mysql.com/doc/refman/5.7/en/charset-mysql.html )

Collation value that compares string in case-sensitive manner needs to be used.
Replacing dbconfig.xml.cmake.in:955 with
//
name LONGTEXT CHARACTER SET utf8 COLLATE utf8_bin NOT NULL
//

Would it work?

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[digikam] [Bug 364131] SCAN : same picture with different file extensions : database scan only finds one variant of the file.

bugzilla_noreply
In reply to this post by bugzilla_noreply
https://bugs.kde.org/show_bug.cgi?id=364131

--- Comment #3 from [hidden email] ---
Please provide an exact patch against git/master...

Gilles

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[digikam] [Bug 364131] SCAN : same picture with different file extensions : database scan only finds one variant of the file.

bugzilla_noreply
In reply to this post by bugzilla_noreply
https://bugs.kde.org/show_bug.cgi?id=364131

--- Comment #4 from [hidden email] ---
Created attachment 99691
  --> https://bugs.kde.org/attachment.cgi?id=99691&action=edit
To remove case insensitivity in MySQL

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[digikam] [Bug 364131] SCAN : same picture with different file extensions : database scan only finds one variant of the file.

bugzilla_noreply
In reply to this post by bugzilla_noreply
https://bugs.kde.org/show_bug.cgi?id=364131

Maik Qualmann <[hidden email]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |[hidden email]

--- Comment #5 from Maik Qualmann <[hidden email]> ---
Yes, the patch works, if a new database is created.

Maik

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[digikam] [Bug 364131] SCAN : same picture with different file extensions : database scan only finds one variant of the file.

bugzilla_noreply
In reply to this post by bugzilla_noreply
https://bugs.kde.org/show_bug.cgi?id=364131

--- Comment #6 from [hidden email] ---
What in case of existing DB?

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[digikam] [Bug 364131] SCAN : same picture with different file extensions : database scan only finds one variant of the file.

bugzilla_noreply
In reply to this post by bugzilla_noreply
https://bugs.kde.org/show_bug.cgi?id=364131

--- Comment #7 from [hidden email] ---
A migration rules must be written. There are a lots of at end of DB XML schema.
Of course the schema revision for Mysql must increased.

Gilles

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[digikam] [Bug 364131] SCAN : same picture with different file extensions : database scan only finds one variant of the file.

bugzilla_noreply
In reply to this post by bugzilla_noreply
https://bugs.kde.org/show_bug.cgi?id=364131

--- Comment #8 from [hidden email] ---
Created attachment 99700
  --> https://bugs.kde.org/attachment.cgi?id=99700&action=edit
To improve schema version

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[digikam] [Bug 364131] SCAN : same picture with different file extensions : database scan only finds one variant of the file [patch]

bugzilla_noreply
In reply to this post by bugzilla_noreply
https://bugs.kde.org/show_bug.cgi?id=364131

[hidden email] changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|SCAN : same picture with    |SCAN : same picture with
                   |different file extensions : |different file extensions :
                   |database scan only finds    |database scan only finds
                   |one variant of the file.    |one variant of the file
                   |                            |[patch]

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[digikam] [Bug 364131] SCAN : same picture with different file extensions : database scan only finds one variant of the file [patch]

bugzilla_noreply
In reply to this post by bugzilla_noreply
https://bugs.kde.org/show_bug.cgi?id=364131

--- Comment #9 from [hidden email] ---
Swaty,

The 2nd patch sound changes a lots of code. Why ? Can you details the patch ?

Gilles

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[digikam] [Bug 364131] SCAN : same picture with different file extensions : database scan only finds one variant of the file [patch]

bugzilla_noreply
In reply to this post by bugzilla_noreply
https://bugs.kde.org/show_bug.cgi?id=364131

--- Comment #10 from [hidden email] ---
Two functions are basically added to update the version in schemaupdater file
1) copyV4toV5()
2) updateV7toV8()

And a dbaction "UpdateSchemaFromV7ToV8" in XML schema file.

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[digikam] [Bug 364131] SCAN : same picture with different file extensions : database scan only finds one variant of the file [patch]

bugzilla_noreply
In reply to this post by bugzilla_noreply
https://bugs.kde.org/show_bug.cgi?id=364131

[hidden email] changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |[hidden email]

--- Comment #11 from [hidden email] ---
*** Bug 268204 has been marked as a duplicate of this bug. ***

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[digikam] [Bug 364131] SCAN : same picture with different file extensions : database scan only finds one variant of the file [patch]

bugzilla_noreply
In reply to this post by bugzilla_noreply
https://bugs.kde.org/show_bug.cgi?id=364131

--- Comment #12 from [hidden email] ---
Created attachment 99735
  --> https://bugs.kde.org/attachment.cgi?id=99735&action=edit
Updated patch

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[digikam] [Bug 364131] SCAN : same picture with different file extensions : database scan only finds one variant of the file [patch]

bugzilla_noreply
In reply to this post by bugzilla_noreply
https://bugs.kde.org/show_bug.cgi?id=364131

[hidden email] changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #99700|0                           |1
        is obsolete|                            |

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[digikam] [Bug 364131] SCAN : same picture with different file extensions : database scan only finds one variant of the file [patch]

bugzilla_noreply
In reply to this post by bugzilla_noreply
https://bugs.kde.org/show_bug.cgi?id=364131

[hidden email] changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #99691|0                           |1
        is obsolete|                            |

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[digikam] [Bug 364131] SCAN : same picture with different file extensions : database scan only finds one variant of the file [patch]

bugzilla_noreply
In reply to this post by bugzilla_noreply
https://bugs.kde.org/show_bug.cgi?id=364131

[hidden email] changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |[hidden email]

--- Comment #13 from [hidden email] ---
Richard,

I would to have your viewpoint about Swati patch to fix this issue, especially
the schema updater part to fix table properties.

Thanks in advance

Gilles Caulier

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[digikam] [Bug 364131] SCAN : same picture with different file extensions : database scan only finds one variant of the file [patch]

bugzilla_noreply
In reply to this post by bugzilla_noreply
https://bugs.kde.org/show_bug.cgi?id=364131

--- Comment #14 from Richard Mortimer <[hidden email]> ---
Changing the collation is the correct thing to do.

Regarding the patch the schema update is required but the v7 to v8 patch needs
to perform an "alter table" command. The update has to assume that the v7
schema is intact and any changes are as specified.

That said before 5.0 is released we need to update the MySQL v7 schema. Whilst
MySQL has never been a stable/supported database the existing 4.x series uses a
base v7 and the existing new database v7 schema has the changes for referential
integrity included. IMHO the v7 to v8 updater should convert the 4.x schema to
the latest schema. Anyone who has been using the 5.x beta series will be able
to "fixup" their schema with a simple version update command. I will dig out my
notes and generate update commands to include in Swati's patch so that the
schema update gets done in a single commit.

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[digikam] [Bug 364131] SCAN : same picture with different file extensions : database scan only finds one variant of the file [patch]

bugzilla_noreply
In reply to this post by bugzilla_noreply
https://bugs.kde.org/show_bug.cgi?id=364131

--- Comment #15 from Maik Qualmann <[hidden email]> ---
Swati,
I think we need case-sensitivity in almost all text fields. I have tested it
once for Albums.relativePath. It does the problem here on, if the path is
different only in case-sensitivity. Is there a global statement for the DB?

Maik

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
12