I recently upgraded from 1.2.6. to 1.2.7 per the upgrade instructions here: http://www.zenphoto.org/2008/08/installation-and-upgrading/ Generally I am working but have a few MSQL/Zenphoto errors that happen when I open a gallery or certain pictures. Please note all the pictures have XMP in them and it seems related to the error. The error when opening the gallery or some images is:
Zenphoto Error
MySQL Query ( INSERT INTO zp_tags (name) VALUES ('text of XMP entires') ) failed. Error: Duplicate entry 'text of XMP entires' for key 2
Any ideas?
Thanks in advance! =)
Are you processing a lot of images at once? There is a check to see if the tag exists already in the database, but maybe there is a race condition where it could get created by another process between the time of the check and the time of the insert.
Otherwise, does this happen with a particular image? Maybe there is something with that image which causes the problem.
You do not need to check. The error your getting is because the tag does exist in the database. Maybe the exact text of the error message would shed some clues (unless, of course, what you posted is the exact text. Then did you mean to have a tag named "Text of XMP entries")
There are actually 8 images in the gallery and only 4 are now showing since the upgrade to 1.2.7. When I click on the Album I get the error message below. As well I get it on the forth image.
The exact text is as follows:
Zenphoto Error
MySQL Query ( INSERT INTO zp_tags (name) VALUES ('Christmas Party 2008 Jim and friends having some fun at Santa's expense') ) failed. Error: Duplicate entry 'Christmas Party 2008 Jim and friends having some fun at Santa's expense' for key 2
Any ideas? Should I check the XMP in the image files themselves?
Do you mean /zenphoto/zp-core/admin-tags.php ??? These are the tags I used to describe the images. I tried deleting the tag that seems to appear twice and I get the following error:
Zenphoto Error
MySQL Query ( INSERT INTO zp_obj_to_tag(objectid, tagid, type) VALUES (11,,'images') ) failed. Error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''images')' at line 1