Uploaded image for project: 'ZABBIX BUGS AND ISSUES'
  1. ZABBIX BUGS AND ISSUES
  2. ZBX-6355

Background image upload fails with "Duplicate entry xx for key PRIMARY"

    Details

    • Type: Incident report
    • Status: Closed
    • Priority: Trivial
    • Resolution: Won't fix
    • Affects Version/s: 2.0.5
    • Fix Version/s: None
    • Component/s: Frontend (F)
    • Environment:
      Debian 6.0.3
      mysql Ver 14.14 Distrib 5.1.49, for debian-linux-gnu (x86_64)
      PHP 5.3.3-7+squeeze3 with Suhosin-Patch (cli)

      Description

      When trying to upload a background image, I get the following error:
      Error in query [INSERT INTO images (imageid, name, imagetype, image) VALUES (42, 'Hintergrund Netzwerkplan', 2, '...')] [Duplicate entry '42' for key 'PRIMARY']

      Looking into table "images" shows me that the last image with imagetype "2" (background) has imageid 41.
      But there are icon images (imagetype "1") up until imageid 228.

      So it seems to me the import logic does something like "select imageid from images where imagetype = 2" instead of "select imageid from images".

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              maxhq Jens Berthold
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: