当前位置:网站首页>Oracle创建表分区后,查询的时候不给出partition,但是会给分区字段指定的值,会不会自动按照分区查询?
Oracle创建表分区后,查询的时候不给出partition,但是会给分区字段指定的值,会不会自动按照分区查询?
2022-07-26 16:20:00 【布衣&凡尘】
Oracle创建表分区后,查询的时候不给出partition,但是会给分区字段指定的值,会不会自动按照分区查询?
采纳答案1:
会:
例:
-- 数据准备:CREATE TABLE t1 ( id number, CD NUMBER (8) NOT NULL) PARTITION BY RANGE(CD)( PARTITION t1_RANGE_10 VALUES LESS THAN (10), PARTITION t1_RANGE_20 VALUES LESS THAN (20), PARTITION t1_RANGE_30 VALUES LESS THAN (30) );insert into t1 values(1,5);insert into t1 values(2,15);insert into t1 values(3,25);select * from t1 partition(t1_RANGE_10);select * from t1 partition(t1_RANGE_20);select * from t1 partition(t1_RANGE_30);SQL> select * from t1 partition(t1_RANGE_10); ID CD---------- ---------- 1 5SQL> select * from t1 partition(t1_RANGE_20); ID CD---------- ---------- 2 15SQL> select * from t1 partition(t1_RANGE_30); ID CD---------- ---------- 3 25


若对答案满意,请点击采纳按钮哦!
其他答案1:
会:
例:
-- 数据准备:CREATE TABLE t1 ( id number, CD NUMBER (8) NOT NULL) PARTITION BY RANGE(CD)( PARTITION t1_RANGE_10 VALUES LESS THAN (10), PARTITION t1_RANGE_20 VALUES LESS THAN (20), PARTITION t1_RANGE_30 VALUES LESS THAN (30) );insert into t1 values(1,5);insert into t1 values(2,15);insert into t1 values(3,25);select * from t1 partition(t1_RANGE_10);select * from t1 partition(t1_RANGE_20);select * from t1 partition(t1_RANGE_30);SQL> select * from t1 partition(t1_RANGE_10); ID CD---------- ---------- 1 5SQL> select * from t1 partition(t1_RANGE_20); ID CD---------- ---------- 2 15SQL> select * from t1 partition(t1_RANGE_30); ID CD---------- ---------- 3 25


若对答案满意,请点击采纳按钮哦!
边栏推荐
- 如何借助自动化工具落地DevOps|含低代码与DevOps应用实践
- Nacos win10 installation and configuration tutorial
- Clojure Web Development -- ring user guide
- ES:Compressor detection can only be called on some xcontent bytes or compressed xcontent bytes
- Compiler analysis of clojure operation principle
- 2022 latest Tibet Construction scaffolder (construction special operation) simulation exam questions and answers
- Clojure operation principle bytecode generation
- VS2017打开项目提示需要迁移的解决方法
- Pat class a 1047 student list for course
- 【万字长文】使用 LSM-Tree 思想基于.Net 6.0 C# 实现 KV 数据库(案例版)
猜你喜欢

Comprehensively design an oppe homepage -- Design of star models
![[physical simulation] the principle and practice of the simplest shape matching](/img/1e/d91ed992bc648d90d0c68bfe541d7e.jpg)
[physical simulation] the principle and practice of the simplest shape matching

Why is digital transformation so difficult?!

vscode批量删除

C#转整型的三种方式的区别以及效率对比

Pat grade a 1050 string subtraction

C#事件和委托的区别

Bugku login1

微信小程序---网络数据请求
![[fluent -- advanced] packaging](/img/aa/bd6ecad52cbe4a34db75f067aa4dfe.png)
[fluent -- advanced] packaging
随机推荐
基于sisotool极点配置PI参数及基于Plecs的三相电压源逆变器仿真
PAT甲级 1046 Shortest Distance
Nacos win10 安装配置教程
操作系统迁移实战之在openEuler上部署MySQL数据库
2022 latest Beijing Construction Safety Officer simulation question bank and answers
Bugku login2
Activity之onCreate、onRestoreInstanceState恢复数据的区别
Linux Installation mysql8.0.29 detailed tutorial
Alibaba cloud DMS MySQL cloud database report error, solve!!
[BJDCTF2020]Easy MD5
kubernetes之探针
Replicationcontroller and replicaset of kubernetes
研发效能的道与术 - 道篇
Pat grade a 1050 string subtraction
【E-MR】NameNode的错误恢复记录
spark-streaming状态流之mapWithState
【物理模拟】超简单的shape matching模拟刚体运动
该怎么写单元测试呢
First knowledge of OpenGL (2) compilation shaders
Probe of kubernetes