Index - Concurrently Method - Mailing list pgsql-admin

From SOzcn
Subject Index - Concurrently Method
Date
Msg-id CAJyV5Abye51ReNuQCcBXpGPYs=VXw6XzQfBHe1HBWafdi66=Fw@mail.gmail.com
Whole thread Raw
Responses Re: Index - Concurrently Method
List pgsql-admin
Hello Guys,

I hope everything is well with you all. 

Is there any other way to use the concurrent method on the table which  has partitioning?

I found something, first of all, it's advised to create the indexes concurrently on your partitioning tables and then create the index on your main after this progress attach the indexes.

Does anybody have any experience with this issue?

I leave the example in the belong. Is that way healthy? At the last time, we gonna create on the main table anyway. So it's kinda confusing me.

By Example;
CREATE INDEX CONCURRENTLY idx_sales_2020_order_date ON sales_2020 (order_date);
CREATE INDEX CONCURRENTLY idx_sales_2021_order_date ON sales_2021 (order_date);
CREATE INDEX CONCURRENTLY idx_sales_2022_order_date ON sales_2022 (order_date);

ALTER INDEX idx_sales_2020_order_date ATTACH PARTITION idx_sales_order_date;
ALTER INDEX idx_sales_2021_order_date ATTACH PARTITION idx_sales_order_date;
ALTER INDEX idx_sales_2022_order_date ATTACH PARTITION idx_sales_order_date;

Have a nice day!

pgsql-admin by date:

Previous
From: Charles Schultz
Date:
Subject: Re: Questions on recovery situations (not urgent)
Next
From: Laurenz Albe
Date:
Subject: Re: Index - Concurrently Method