O
O
ozornick2017-04-02 13:35:27
PostgreSQL
ozornick, 2017-04-02 13:35:27

How to name indexes in PostgreSQL?

What are the rules for indexes? I create, for example, uniqName for the Users table. Then I try to create a uniqName for Themes (let's say blog topics). I get an error saying the index already exists. So what is the best way to name indexes? And wouldn't a big name like themes_uniq_name, users_uniq_name or compound users_uniq_name_user_id (something like that) be a brake?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
sim3x, 2017-04-02
@ozornick

www.stackoverflow.com/a/4108266

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question