HomePhabricator

Fix PostgreSQL patch-add-3d.sql by replacing it

Authored by Anomie on Sep 15 2017, 4:12 PM.

Description

Fix PostgreSQL patch-add-3d.sql by replacing it

Follows-up 6260545fee, a2f5d05ae8. (T157348)

If updates are run for the first time on an installation that already
has '3D' in the enum (e.g. because it's a fresh install), the update
fails.

Instead of blindly running a patch file, we instead add a method that
checks whether the enum type already contains the value before adding
it.

Bug: T177417
Change-Id: Iad10cb88cf1cb35cfb95ce98a556b33688158a88
(cherry picked from commit 5ba7fb251e0ac09f3171f41320c2c1b60b8b983c)

Details