oceanbase mysql 测试_oceanbase测试预研(持续更新)

本文记录了使用OceanBase数据库进行MySQL兼容性测试的过程。通过安装obclient,连接OceanBase服务器并执行SQL查询,观察其行为。在查询过程中遇到了表不存在的错误,但展示了OceanBase的查询计划和执行过程。
摘要由CSDN通过智能技术生成

[root@linux-dev ~]# rpm -ivh obclient-1.1.1-20190802211743.el7.alios7.x86_64.rpm

准备中... #################################[100%]正在升级/安装...1:obclient-1.1.1-20190802211743.el7################################# [100%]

[root@linux-dev ~]# obclient -h10.19.1.23 -P2883 -usys@oracle_tenant0_1#obtest -p123456 -c -A sys

obclient:[Warning] Using a password onthe command line interface can be insecure.

Welcometo the OceanBase monitor. Commands end with ; or\g.

Your OceanBase connection idis 1652791Server version:5.6.25 OceanBase 2.2.30 (r20200807074943-8db774b3cae3e41d7b06a2c9c82a2bee97eba0c0) (Built Aug 7 2020 08:06:34)

Copyright (c)2000, 2018, Oracle and/or its affiliates. Allrights reserved.

Oracleis a registered trademark of Oracle Corporation and/orits

affiliates. Other names may be trademarksoftheir respective

owners.

Type'help;' or '\h' for help. Type '\c' to clear the currentinput statement.

obclient> explain select * from ob_t_1 t,ob_t_2 t1 where t.id=t1.id->;

ERROR-00942: table or view 'SYS.OB_T_1' does notexist

obclient> explain select * from t,t1 where t.id=t1.id->;+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+

| Query Plan |

+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+

| ======================================

|ID|OPERATOR |NAME|EST. ROWS|COST |

--------------------------------------

|0 |HASH JOIN | |99000 |592998|

|1 | TABLE SCAN|T |100000 |68478 |

|2 | TABLE SCAN|T1 |100000 |61860 |

======================================Outputs&filters:-------------------------------------

0 - output([T.ID], [T.NAM], [T1.ID], [T1.NAM]), filter(nil),

equal_conds([T.ID = T1.ID]), other_conds(nil)1 - output([T.ID], [T.NAM]), filter(nil),

access([T.ID], [T.NAM]), partitions(p0)2 - output([T1.ID], [T1.NAM]), filter(nil),

access([T1.ID], [T1.NAM]), partitions(p0)|

+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+

1 row in set (0.00sec)

obclient> exitBye[root@linux-dev ~]# ob

obclient objcopy objdump[root@linux-dev ~]# obclient -h10.19.1.23 -P2883 -uroot@mysql_teant0_2#obtest -p123456 -c -A oceanbase

obclient:[Warning] Using a password onthe command line interface can be insecure.

Welcometo the OceanBase monitor. Commands end with ; or\g.

Your OceanBase connection idis 1652810Server version:5.6.25/*这基本上就是基于mysql 5.6.25*/ OceanBase 2.2.30 (r20200807074943-8db774b3cae3e41d7b06a2c9c82a2bee97eba0c0) (Built Aug 7 2020 08:06:34)

Copyright (c)2000, 2018, Oracle and/or its affiliates. Allrights reserved.

Oracleis a registered trademark of Oracle Corporation and/orits

affiliates. Other names may be trademarksoftheir respective

owners.

Type'help;' or '\h' for help. Type '\c' to clear the currentinput statement.

obclient> explain select * from ob_t_1 t,ob_t_2 t1 where t.id=t1.id;

ERROR1146 (42S02): Table 'oceanbase.ob_t_1' doesn't exist

obclient> use test;

Database changed

obclient> explain select * from ob_t_1 t,ob_t_2 t1 where t.id=t1.id;

+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+

| Query Plan |

+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+

| =================================================================

|ID|OPERATOR |NAME |EST. ROWS|COST |

-----------------------------------------------------------------

|0 |EXCHANGE IN DISTR | |100001 |402319|

|1 | EXCHANGE OUT DISTR |:EX10001|100001 |274528|

|2 | MERGE JOIN | |100001 |274528|

|3 | EXCHANGE IN MERGE SORT DISTR | |100000 |125756|

|4 | EXCHANGE OUT DISTR (BROADCAST)|:EX10000|100000 |61860 |

|5 | TABLE SCAN |t |100000 |61860 |

|6 | TABLE SCAN |t1 |100000 |61860 |

=================================================================

Outputs & filters:

-------------------------------------

0 - output([t.id], [t.nam], [t1.id], [t1.nam]), filter(nil)

1 - output([t.id], [t.nam], [t1.id], [t1.nam]), filter(nil), dop=1

2 - output([t.id], [t.nam], [t1.id], [t1.nam]), filter(nil),

equal_conds([t.id = t1.id]), other_conds(nil)

3 - output([t.id], [t.nam]), filter(nil), sort_keys([t.id, ASC])

4 - output([t.id], [t.nam]), filter(nil), dop=1

5 - output([t.id], [t.nam]), filter(nil),

access([t.id], [t.nam]), partitions(p0)

6 - output([t1.id], [t1.nam]), filter(nil),

access([t1.id], [t1.nam]), partitions(p0)

|

+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+

1 row in set (0.01 sec)

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值