??????????
??????????????create table ‘????’(‘gradeid’ int(11) auto_increment primary key????primary key(‘gradeid’))
??????????create table ‘grade’(‘gradeid’ int(11) auto_increment primary key??’gradename’ varchar(32) not null unique ??unique key ‘gradeid’(‘gradeid’))
???????Unique key ?????????????????????????????????
????????????(index)??create table ‘result’(…index/key ‘ind’(‘studentNo’??’subjectNo’))   ????????
????Alter table ‘result’ add index ‘ind’ (‘studentNo’??’subjectNo’);     ?????????
????????create table test(
????A int primary key??B char(5) unique??C int??D int??
????Key ‘index_cd’ (‘c’??’d’)??
??????  Index ‘index_c’(‘c’)
????#primary key(‘a’)   #unique key ‘index_b’ (‘b’)
????)???????????????????????????????μ???????????????
?????????????create table ‘student’(…fulltext(‘studentName’)engine=myisam);
????Alter table employee add fulltext(‘first_name’)
???????????????λ????????????????myisam??????????????????char??varchar??text??????????????????????
????Select * from test where match(‘studentNmae’) against(‘key’);   ???test???????????????studenname?????????????key???????????
?????????????
????Drop index ?????? on ????
????Alter table ???? drop index ??????
????Alter table ???? drop primary key
????????????
????Show index(??keys) from ????
?????????
????Msqldump????????bin????????????????
????Mysqldump -h ?????? -u ????? -p [options] ??????? [table 1 table2 table3] >path/filename.sql
???????磺????bdqn?????cmd????dos?????????
????mysqldump -u root -p bdqn bdqn category users > d:/sqlbk.sql
????Mysqldump???????
????Mysqldump -help    ??????????
????--add-drop-table   ????sql????????drop table if exists??????????????????
????--skip-add-drop-table???
????????Mysqldump -uroot -pbdqn –-skip-add-drop-table bdqn category users >d:sqlbk.sql
????--add-locks   ????insert????????????lock table??unlock table???
???????????????????ε??????????????????е??????????????
????-t??--no-create-info  ????????????д?????????
????????Mysqldump -uroot -pbdqn –-no-create-info bdqn category users >d:sqlbk.sql
????-c??--complete-insert  ?????inseert??????????????????????????????????????????
????????Mysqldump -uroot -pbdqn –c bdqn category users >d:sqlbk.sql
????-d??—no-data  ????????????????
????--where ’where-condition’??-w’ where-condition’   ??????????where??????????
????????Mysqldump -uroot -pbdqn –-where ‘studentNo=1’ bdqn student>d:sqlbk.sql
????????????
?????????????source???? source /path/db_name.sql
???????/path/?????·?????????????mysql?????????????????????source??mysql???????????
????????mysql -uroot -pbdqn;
????Use test;
????source d:sqlbk.sql
??????????????mysql?????  mysql-u root -p dbname< /path/db_name.sql;
????????mysql -uroot -pbdqn test <d:sqlbk.sql