n->skipIfNewValExists = false;
$$ = (Node *) n;
}
+ | ALTER TYPE_P any_name DROP VALUE_P Sconst
+ {
+ /*
+ * The following problems must be solved before this can be
+ * implemented:
+ *
+ * - There must be no instance of the target value in
+ * any table.
+ *
+ * - The value must not appear in any catalog metadata,
+ * such as stored view expressions or column defaults.
+ *
+ * - The value must not appear in any non-leaf page of a
+ * btree (and similar issues with other index types).
+ * This is problematic because a value could persist
+ * there long after it's gone from user-visible data.
+ *
+ * - Concurrent sessions must not be able to insert the
+ * value while the preceding conditions are being checked.
+ *
+ * - Possibly more...
+ */
+ ereport(ERROR,
+ (errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
+ errmsg("dropping an enum value is not implemented"),
+ parser_errposition(@4)));
+ }
;
opt_if_not_exists: IF_P NOT EXISTS { $$ = true; }