欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页  >  IT编程

mysql下修改engine引擎的方法

程序员文章站 2024-02-11 19:44:16
修改my.ini,在[mysqld]下加上     default-storage-engine=innodb  其中红色字体...
修改my.ini,在[mysqld]下加上

    default-storage-engine=innodb 

其中红色字体部分是要指定的引擎名称。

用sql语句修改已经建成表的引擎:

alter table tablename type=innodb

下面贴出我的my.ini文件供参考():

[mysqld]
basedir=c:\program files\vertrigoserv\mysql\
datadir=c:\program files\vertrigoserv\mysql\data\
port =3306
key_buffer =64m
max_allowed_packet =1m
table_cache =128
sort_buffer_size =512k
net_buffer_length =8k
read_buffer_size =256k
read_rnd_buffer_size =512k
myisam_sort_buffer_size =68m
default-storage-engine=innodb

[mysqldump]
quick
max_allowed_packet =116m

[mysql]
no-auto-rehash
# remove the next comment character if you are not familiar with sql
#safe-updates

[isamchk]
key_buffer =20m
sort_buffer_size =20m
read_buffer =62m
write_buffer =62m

[myisamchk]
key_buffer =20m
sort_buffer_size =20m
read_buffer =62m
write_buffer =62m

[mysqlhotcopy]
interactive-timeout