测试MySQL5.7下binary(16)与varchar(32)写表性能

    xiaoxiao2022-07-03  120

    create table testuuid( id binary(16) primary key, name varchar(100) ) insert into testuuid(id,name)values(unhex(REPLACE(UUID(),'-','')),?) 写入1万条数据16秒

    create table testuuid2( id varchar(32) primary key, name varchar(100) ) insert into testuuid2(id,name)values(REPLACE(UUID(),'-',''),?) 写入1万条数据29秒

    create table testuuid3( id char(32) primary key, name varchar(100) ) insert into testuuid3(id,name)values(REPLACE(UUID(),'-',''),?) 写入1万条数据28秒

    最新回复(0)