"Refresh the Database" does not work as I would expect. Because it reset all records in the images table, e.g. the title becomes image name, the sorting is gone, the link to the tags does not work anymore and... This is not a garbage collection, it's a kind of a reset function! If this behaviour is correct, please rename the button!
The button does just what it's title says.
It examines the database, removes orphaned records (ones where the file no longer exists). It also cleans up invalid records such as those where the file name starts with a slash or has double slashes, etc.
If some of those invalid records did contain your titles, etc. then they may well have been discarded. But they were not valid records to start with.
You can, of course, restore your database from a backup and manually fix those records.
The previous release (1.4.5.5) did what you said. But now, zp deletes every record (independed if it's valid or not) and writes a new one. All the manually entered text is gone (like image titles etc). Since the old image id's does not exist anymore, all links to the 'obj_to_tag' table become invalid! That's really bad.
I cannot specify "good metadata" as there is no such. Some programs use EXIF/IPTC fields not as defined in the official standards. But we follow those standards naturally.
Anway, this is for sure not your issue and I can only repeat what sbillard already said above. I cannot reproduce any issues.
Let us be perfectly clear.
Refresh database (garbage collect) does not cause any metadata refresh directly. But certainly if the garbage collect detects flawed database records and removes and then Zenphoto re-discovers the album the database record will be recreated correctly.
Quote:If i have "Musées du Monde" as dynamic album, i rename it as "musees" for example, then after i meet the problem.
There are two possibilities here since you were far from clear as to what you did. If you renamed the folder on your file system then Zenphoto would consider it a new album of course.
It is also possible that your file system has difficulties with files with diacritical marked characters. This is often the case when the file system is UTF-8 and you have not told Zenphoto.
I probably found the reason for this behaviour. Following situations:
ZP 1.4.5.5
Press "Set as thumbnail for" in edit images in the backend-> ZP generates wrong records in album/images table (leading/trailing slashes in names) -> remove them manually in the DB -> ZP generates new invalid records, when I view the gallery again
Update from 1.4.5.5 to 1.4.5.7 (last build from github)
First try:
Starting setup process to update to new version (no errors) -> Album/images table looks ok -> View gallery -> Album/images table completely rewritten (new id’s, all manual text gone, link to tags table become invalid, etc)
Second try:
Starting setup process to update to new version (no errors) -> Album/images table looks ok -> remove just the invalid album records with leading or trailing slashes in DB manually and leave images table untouched -> View gallery -> Album/images tables are untouched by ZP, everything looks good -> Press "Refresh the Database": ZP found the wrong image records and removed them -> DB ok (no invalid records), Gallery look ok
It seems that ZP has problems with DB records containing leading/trailing slashes in albums. In this case it rewrites the entire album/images table, at least on my system...
there was an serious issue with diacritical marks in 1.4.5.6 which is why we release 1.4.5.7 one day after it. There was also an issue with trailing slashes that should not be there in certain places.
Please create a ticket so sbillard more easily sees it later.
Quote:It seems that ZP has problems with DB records containing leading/trailing slashes in albums. In this case it rewrites the entire album/images table, at least on my system...
Perhaps you missed it the first time I told you that this was the problem. And maybe you missed it again the second time. And maybe again the third time....
Also you seem to miss the normal suggestion that if you are having a problem you should at least try to see if the support build corrects it. You can do this either by installing it or by perusing the changes to the release to see if anything fits.
Hi guys,
I've got the same problem with some albums name in my DB, Zenphoto adds a slash before some of them.
As suggested, I remove them manually because they only appear in the search results.
I've noticed that they are created at the same time than the regular named albums.
Zenphoto 1.4.5.7
MySQLi : 5.1.67
PHP : 5.3.22
encoding : fr_FR.UTF8
This is weird. I'd like to prevent it to happen again.
Well, guys,
as mentioned above, my ZP version is a 1.4.5.7 one (updated step by step from a 1.4.5.2 fresh installation).
Stephen, as mentioned above, I gave some informations about my settings,
here they are again :
Zenphoto 1.4.5.7 [59c22b2fba]
MySQLi : 5.1.67
PHP : 5.3.22
encoding : fr_FR.UTF8
theme : lightly modified ZPskeleton
would you mind saying to me what do you need to go further ?