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

history_text_2 doesn't need to be a unique index

XMLWordPrintable

    • Icon: Incident report Incident report
    • Resolution: Duplicate
    • Icon: Trivial Trivial
    • None
    • 2.0.6
    • Server (S)
    • Centos 6.4 x64, PostgreSQL 9.1

      history_text table on PostgreSQL has 3 indexes:
      "history_text_pkey1" PRIMARY KEY, btree (id)
      "history_text_2" UNIQUE, btree (itemid, id)
      "history_text_1" btree (itemid, clock)

      Since the primary key is already unique, the history_text_2 index doesn't need to be unique at all.

      Also why does the history_text table out of all history tables the only one that has additional two indexes besides the (itemid, clock) index? Are they really needed.

            Unassigned Unassigned
            kustodian Strahinja Kustudic
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: