How to use uuid with postgresql gist index type?
问题 I can't use directly uuid with gist index CREATE INDEX idx_leaderboads_values_gist ON leaderboard_entry USING gist (id_leaderboard , value); And I got this error: ERROR: data type uuid has no default operator class for access method "gist" HINT: You must specify an operator class for the index or define a default operator class for the data type. 回答1: Postgres 10 or newer btree_gist now also covers the data type uuid , like Paul commented. (And some other data types, remarkably all enum types