Comments (2)
1.版本号测试
./mysqld --version
2.DDL
建库:
create database if not exists stdb character set utf8mb4;
建表:
use stdb ;
create table person(id int, name varchar(20)) engine=tianmu;
更改表结构:
desc person;
show create table person;
alter table person drop column id;
alter table person add column id int;
删除:
drop table person;
drop database stdb ;
3.DML
插入:
insert into person (id, name) value (1, " zhangsan "),(2, " lisi ");
修改:
update person set name= " wangwu " where id=2;
删除:
delete from person where id=1;
4.DQL
查询:
select * from person where id=2;
in用法:
create table tin(id int,name varchar(25),sex varchar(25)) engine=tianmu;
insert into tin values(1,"atom","male");
insert into tin values(2,"atomdb","male");
insert into tin values(3,"atomdb","male");
insert into tin values(5,"atomdb","male");
insert into tin values(4,"atomdb","male");
select * from tin where id in (1,3,4);
select * from tin where id in (select id from tin);
自增用法:
create table tin(id int,name varchar(25),sex varchar(25)) engine=tianmu;
insert into tauto(name,sex) values("atom",1);
insert into tauto(name,sex) values("atom",2);
insert into tauto(name,sex) values("atom",3);
select * from tauto;
5.大数据量性能测试
create table t8(id int,
a varchar(10) comment "LOOKUP",
b varchar(10),
c varchar(10),
d varchar(10),
e varchar(10),
f varchar(10),
g varchar(10)
) ENGINE=tianmu;
delimiter ;;
create procedure idata8()
begin
declare i int;
set i=1;
while(i<=1000000)do
insert into t8 values(i, '1234567890','1234567890','1234567890','1234567890','1234567890','1234567890','1234567890');
set i=i+1;
end while;
commit;
end;;
delimiter ;
call idata8();
from mysql-server-mysql-8.0.30.
6.索引测试
非主键索引:
create database db1;
use db1;
create table tindex(id int, name varchar(25), index(name)) engine=tianmu;
insert into tindex values(1,"sss");
insert into tindex values(1,"zz");
insert into tindex values(1,"www");
select * from tindex where name="ss";
主键索引:
CREATE TABLE tauto
(
id
int(11) NOT NULL AUTO_INCREMENT,
name
varchar(25) DEFAULT NULL,
sex
varchar(25) DEFAULT NULL,
PRIMARY KEY id
(id
)
) ENGINE=tianmu DEFAULT CHARSET=utf8 ;
insert into tauto(name, sex) values("ss","sss");
insert into tauto(name, sex) values("zz","zzz");
insert into tauto(name, sex) values(:"ww","www");
select * from tautowhere name="ss";
7.varchar类型主键插入空值
CREATE TABLE haha
(name VARCHAR(25),
deptId INT(11),
salary FLOAT,
PRIMARY KEY(name)) engine=tianmu;
INSERT INTO haha(deptId,salary) values (13,888);
from mysql-server-mysql-8.0.30.
Related Issues (20)
- TODO: Need to test supported/unsupported operations、data types for StoneDB 8.0
- TODO:InnoDB is limited to row-logging by MySQL 8.0 HOT 1
- TODO: Give suggested my.cnf about MySQL 8.0 HOT 2
- TODO: execute_sqlcom_select is deleted HOT 2
- TODO: handle_query is deleted HOT 2
- TODO: add build scripts
- TODO: R&D self-test DDL HOT 6
- TODO: R&D self-test DML HOT 2
- TODO: mtr
- TODO: uncomment RCTable::binlog_load_query_log_event HOT 1
- TODO: uncomment export_file_name from `engine_execute.cpp` HOT 1
- TODO: check TODO on the comments HOT 9
- Evaluate: rr_sequential VS rr_quick
- TODO: R&D self-test DQL basically HOT 1
- TODO: R&D self-test TPCH HOT 1
- fix:mysqld...Segmentation fault HOT 1
- TODO: Add Engine::HandleSelect to MySQL 8.0 HOT 1
- lock_tables
- Crash: use db
- crash: query_compile.cpp
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mysql-server-mysql-8.0.30.