postgresql 不阻塞创建索引
来源:互联网 发布:号码数据库 编辑:程序博客网 时间:2024/06/05 21:12
通常在postgresql创建普通索引如下
create index idx_table_name_x1 on table_name(col_name);
执行后在创建索引期间会阻塞 dml,如果是在比较繁忙的系统或者大表上执行该语句的话,估计很快就会有人问候你了。
所以应该使用 concurrently 参数:
create index concurrently idx_table_name_x1 on table_name(col_name);
同样 oracle 也有类似的方法,如下 :
create index idx_table_name_x1 on table_name(col_name) online ;
阅读全文
0 0
- postgresql 不阻塞创建索引
- PostgreSQL创建索引例子
- Postgresql客户端创建GIN索引问题
- PostgreSQL索引创建方法及相关问题
- PostgreSQL索引
- Postgresql 索引
- postgresql索引
- mysql 5.6 创建索引导致表锁阻塞查询
- Oracle索引创建——新增数据创建索引,历史数据不创建索引
- 如何创建索引、什么时候该创建、什么时候不应该创建
- 如何创建索引、什么时候该创建、什么时候不应该创建
- 创建索引为什么是灰色,不可用??
- PostgreSql查看索引
- PostGresql索引深入分析
- PostgreSQL学习手册(索引)
- PostgreSQL 位图索引
- postgresql 索引类型
- postgresql 索引类型
- Spring Cloud Commons 普通抽象
- Angular练习之animations动画
- android圆形进度条
- 父类引用调用子类对象
- springboot(六):如何优雅的使用mybatis
- postgresql 不阻塞创建索引
- C++基于对象--Class without pointer
- USB设备请求
- Road of poj-1002
- 3模型训练和最优化-3.2模型训练之梯度下降与参数更新
- The Importance of Acquiring the Methods of Gaining Knowledge Rather Than Knowledge Itself
- oracle数据库自动提交
- python -- 0/1背包问题(动态规划-list)
- 物理standby中switchover时switchover pending的解决办法