In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-04-05 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)06/01 Report--
A normal index is usually created in postgresql as follows
Create index idx_table_name_x1 on table_name (col_name)
After reate index execution, dml is blocked during index creation, and adding the concurrently parameter to create the index does not block dml.
Create an index:
CREATE INDEX idx_t_info ON "public" .t _ info (code)
Create an index online:
CREATE INDEX concurrently idx_t_info ON "public" .t _ info (code)
Rebuild a single index:
REINDEX INDEX my_index
Rebuild the index related to table my_table
REINDEX TABLE my_table
Rebuild all indexes under the broken_db database:
REINDEX DATABASE broken_db
Create a unique index:
CREATE UNIQUE INDEX idx_t_info ON t_info (name1)
Function index:
CREATE INDEX concurrently idx_t_info ON t_info (lower (name1))
Partial index
CREATE INDEX concurrently idx_t_info ON t_info (code) where (code > 5)
Delete the index:
Drop index idx_t_info
Index renaming:
Alter index idx_t_info rename to idx_t_info1
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.