|
-- ·|û / µù¥U --
|
¡@ |
|
|
MySQL§Þ³N¤j¥þ¡G¶}µo¡BÀu¤Æ»P¹Bºû¹ê¾Ô¡GµøÀW±Ð¾Çª© ( ²Åé ¦r) |
§@ªÌ¡G¦Bªe ½sµÛ | Ãþ§O¡G1. -> ¸ê®Æ®w -> MySQL |
ĶªÌ¡G |
¥Xª©ªÀ¡G¾÷±ñ¤u·~¥Xª©ªÀ | 3dWoo®Ñ¸¹¡G 53710 ¸ß°Ý®ÑÄy½Ð»¡¥X¦¹®Ñ¸¹¡I¡i¦³®w¦s¡j NT°â»ù¡G 995 ¤¸ |
¥Xª©¤é¡G11/1/2020 |
¶¼Æ¡G726 |
¥úºÐ¼Æ¡G0 |
|
¯¸ªø±ÀÂË¡G |
¦L¨ê¡G¶Â¥Õ¦L¨ê | »y¨t¡G ( ²Åé ª© ) |
|
¥[¤JÁʪ«¨® ¢x¥[¨ì§Úªº³Ì·R (½Ð¥ýµn¤J·|û) |
ISBN¡G9787111668985 |
§@ªÌ§Ç¡@|¡@ĶªÌ§Ç¡@|¡@«e¨¥¡@|¡@¤º®e²¤¶¡@|¡@¥Ø¿ý¡@|¡@§Ç |
(²Åé®Ñ¤W©Òz¤§¤U¸ü³sµ²¯Ó®É¶O¥\, ®¤¤£¾A¥Î¦b¥xÆW, YŪªÌ»Ýn½Ð¦Û¦æ¹Á¸Õ, ®¤¤£«OÃÒ) |
§@ªÌ§Ç¡G |
ĶªÌ§Ç¡G |
«e¨¥¡G¬°¦ón¼g³o¥»®Ñ
¡@¡@MySQL¨ã¦³¤p¥©¡BÆF¬¡©M§K¶Oµ¥¯S©Ê¡A³o¨Ï±o¥¦¶V¨Ó¶V¦h¦a³Q¥Î¤_¥ø·~ªº¹ê»Ú¶}µo¤¤¡C¯S§O¬OMySQL¼Æ¾Ú®wªº¶}·½¯S©Ê¡A§ó¨Ï¥¦±o¨ì¤F¼sªxÀ³¥Î¡Cµ{§Çûn·Q¶i¤JMySQL¶}µo»â°ì¡A°£¤F»Ýn¦³¤ã¹êªº½sµ{°ò¦¥~¡AÁÙ»Ýn´x´¤SQL»y¥yªº½s¼g¡A¼ô±xMySQL¼Æ¾Ú®wªºÀu¤Æ©M¹Bºû¡A¤F¸ÑMySQL¼Æ¾Ú®wªº±`¨£¬G»Ù©M¸Ñ¨M¤è®×¡A³o¼Ë¤~¯à¦bÄvª§¤é¯q¿E¯Pªº¼Æ¾Ú®w»â°ì´£°ªÄvª§¤O¡A¶i¦Ó¹ê²{¦Û¨ªº»ùÈ¡C
¡@¡@¥Ø«e¡A¥«±¤W¤¶²ÐMySQL¼Æ¾Ú®w§Þ³Nªº¹Ï®Ñ¤£¤Ö¡A¦ý¬O¯u¥¿±q¹ê¾Ô¥Xµo¡A¥þ±¤¶²ÐMySQL°ò¦¡BÀô¹Ò·f«Ø¡B¶}µo¡BÀu¤Æ¡B¹Bºû©M¬[ºcªº¹Ï®Ñ«o«Ü¤Ö¡C¥»®Ñµ²¦X¤j¶qªº¹ê¾Ô®×¨Ò¡A¸Ô²Ó¦a¤¶²Ð´x´¤MySQL¼Æ¾Ú®w©Ò»Ýnªº¦U¶µ§Þ¯à¡A¤×¨ä¬OÀô¹Ò·f«Ø¡BMySQLÀu¤Æ¡BMySQL¹Bºû©M¬[ºcµ¥¬ÛÃö¤º®e¡C³q¹L¾\Ū¥»®Ñ¡AŪªÌ¯à°÷§ó¥[¥þ±¡B²`¤J¡B³z¹ý¦a²z¸ÑMySQL¼Æ¾Ú®w§Þ³N¡A¹ï®Ñ¤¤©Òz¤º®eµy¥[קï«K¥iª½±µÀ³¥Î¤_¦Û¤vªº¤u§@¤§¤¤¡A±q¦Ó´£°ª¦Û¨ªºMySQL¶}µo¤ô¥©M¶µ¥Ø¹ê¾Ô¯à¤O¡C
¥»®Ñ¯S¦â
¡@¡@1¡D´£¨Ñªñ15¤p®É°t®M±Ð¾ÇµøÀW
¡@¡@¬°¤FÅýŪªÌ§ó¥[°ª®Ä¡Bª½Æ[¦a¾Ç²ß©M²z¸Ñ¥»®Ñ¤¤ªº«ÂI¤º®e©MÃøÂI¤º®e¡Aµ§ªÌ±Mªù¿ý¨î¤Fªñ15¤p®É¡]¦@84¬q¡^ªº°t®M±Ð¾ÇµøÀW»²§UŪªÌ¾Ç²ß¡A¬Û«HŪªÌµ²¦X±Ð¾ÇµøÀW¡A¥i¥H¨ú±o§ó¦nªº¾Ç²ß®ÄªG¡C
¡@¡@2¡D¤º®e«D±`¥þ±¡A²[»\MySQLªº©Ò¦³«n§Þ³NÂI
¡@¡@¥»®Ñ«D±`¥þ±¦a¤¶²Ð¤FMySQL¼Æ¾Ú®wªº¦UÓª¾ÃÑÂI¡A²[»\MySQL°ò¦ª¾ÃÑ¡BÀô¹Ò·f«Ø¡B¶}µo¡BÀu¤Æ¡B¹Bºû©M¬[ºcµ¥¡C³q¹L¾\Ū¥»®Ñ¡AŪªÌ¯à°÷¥þ±´x´¤MySQL¼Æ¾Ú®wªº¦U¶µ§Þ³NnÂI¡C
¡@¡@3¡Dµ¹¥X¤j¶qªº¹Ï¸Ñ©M¹ê¾Ô®×¨Ò
¡@¡@¥»®Ñ¦b¤¶²Ð²z½×ª¾ÃѮɳ£°t¦³¹ïÀ³ªº¹Ïªí¡A¦Ó¥B¦bª¾ÃÑÂIÁ¿¸Ñ¦Z³£µ¹¥X¤F¤j¶qªº¹ê¾Ô®×¨Ò¡AÀ°§UŪªÌ§ó¥[ª½Æ[¦a²z¸Ñ©Ò¾Ç¤º®e¡CŪªÌ¥un«Ü¦n¦a²z¸Ñ¦UÓª¾ÃÑÂI¦}¿Ë¦Û°Ê¤â¹B¦æ¨CӥܨҪº·½¥N½X¡A´N¯à°÷§ó¥[²`¤J¦a²z¸Ñ©M¨Ï¥ÎMySQL¡C
¡@¡@4¡D®×¨Ò¨å«¬¡A¹ê¥Î©Ê±j
¡@¡@¥»®Ñ¤¤ªº¹ê¾Ô®×¨Ò¯A¤ÎMySQL§Þ³Nªº¤è¤è±±¡A³£«D±`¨å«¬¡A¦Ó¥B³o¨Ç®×¨Ò¨ã¦³«Ü±jªº¹ê¥Î©Ê¡A²¤¥[קï´N¥i¥H¾E²¾¨ì¦Û¤vªº¤u§@¤¤¡AŪªÌ¥un«Ü¦n¦a²z¸Ñ©M´x´¤³o¨Ç®×¨Ò¡A´N¯àIJÃþ®Ç³q¡AÁ|¤@¤Ï¤T¡C
¡@¡@5¡DÁ¿¸Ñ³q«U©öÀ´
¡@¡@¥»®Ñ±q©l¦Ü²×³£¥Î³q«U©öÀ´ªº»y¨¥¶i¦æÁ¿¸Ñ¡A®Ñ¤¤¹ï¨CÓ·§©À³£µ¹¥X¤F²M´·ªº©w¸q¡A¹ï¨CÓª¾ÃÑÂI³£µ¹¥X¤F²©ú§ãnªºÁ¿¸Ñ¡A¹ï¨CӮרҳ£µ¹¥X¤F²M´·©ú¤Fªº¹ê²{¨BÆJ¡A¦Ó¥BÁ¿¸Ñ®É¨¥Â²·N¸ð¡A³o¤j¤j´£¤É¤FŪªÌªº¾\ŪÅéÅç¡C
¥»®Ñª¾ÃÑÅé¨t
¡@¡@²Ä1½g MySQL°ò¦
¡@¡@¥»½g²[»\²Ä1¡ã3³¹¡A¥Dn¤¶²Ð¼Æ¾Ú®wªº©w¸q»Pµo®i¡A¥H¤Î¼Æ¾Ú®w§Þ³N¡BMySQL¼Æ¾Ú®wªº¤T¤jS¦¡¤Î¦sÀx¤ÞÀº¡C
¡@¡@²Ä2½g Àô¹Ò·f«Ø
¡@¡@¥»½g²[»\²Ä4¡ã6³¹¡A¥Dn¤¶²Ð¦p¦ó¦w¸ËVMwareµêÀÀ¾÷¡A¦p¦ó¦w¸ËWindows¡BMac OS X©MCentOS¾Þ§@¨t²Î¡A¥H¤Î¦p¦ó¦b¤T¤j¾Þ§@¨t²Î¤W¦w¸Ë©M°t¸mMySQLÀô¹Ò¡C
¡@¡@²Ä3½g MySQL¶}µo
¡@¡@¥»½g²[»\²Ä7¡ã19³¹¡A¥Dn¤¶²ÐMySQLªº§Þ³NnÂI¡A¥]¬A¦p¦ó¾Þ§@¼Æ¾Ú®w©M¼Æ¾Úªí¡AMySQL¤¤ªº¼Æ¾ÚÃþ«¬¡B¹Bºâ²Å¡B¨ç¼Æ¡B¼Æ¾ÚÅܧó©M¼Æ¾Ú¬d¸ß¡AMySQL¤¤ªº¯Á¤Þ¡Bµø¹Ï¡BIJµo¾¹¡B¦sÀx¹Lµ{©M¨ç¼Æ¡A¥H¤ÎMySQL¤À°Ï¡B¤½¥Îªíªí¹F¦¡»P¥Í¦¨¦C¡C
¡@¡@²Ä4½g MySQLÀu¤Æ
¡@¡@¥»½g²[»\²Ä20¡ã26³¹¡A¥Dn¤¶²ÐMySQL¤¤ªº¬d¸ßÀu¤Æ¡B¯Á¤ÞÀu¤Æ¡BSQL»y¥yÀu¤Æ¡B¼Æ¾Ú®wÀu¤Æ¡BªA°È¾¹Àu¤Æ¡BÀ³¥Îµ{§ÇÀu¤Æ¤Î¨ä¥LÀu¤Æ§Þ³Nµ¥¡C
¡@¡@²Ä5½g MySQL¹Bºû
¡@¡@¥»½g²[»\²Ä27¡ã30³¹¡A¥Dn¤¶²ÐMySQL¤¤¦UºØ©R¥O¦æ¤u¨ãªº¨Ï¥Î¡A¦UºØ¤é§Óªº¶}±Ò¡B¬d¬Ý¡B§R°£»PÃö³¬¡A¼Æ¾Úªº³Æ¥÷»P«ì´_¡A¥H¤ÎMySQL¤¤ªº½ã¤áºÞ²zµ¥¡C
¡@¡@²Ä6½g MySQL¬[ºc
¡@¡@¥»½g²[»\²Ä31¡ã33³¹¡A¥Dn¤¶²Ð¦p¦ó¹ê²{MySQL¤¤ªº´_¨î¡A¦p¦ó·f«ØMySQLªºÅª¼g¤ÀÂ÷Àô¹Ò¡A¥H¤Î¦p¦ó¹ê²{MySQLªº°ª¥i¥Î©Êµ¥¡C
°t®Ñ¸ê·½Àò¨ú
¡@¡@¥»®ÑªþÃئp¤U°t®Ñ¸ê·½¡G
* ªñ15¤p®É¡]¦@84¬q¡^°t®M±Ð¾ÇµøÀW¡F
* ©Ò¦³®×¨ÒªºSQL·½½X¤å¥ó¡C
¡@¡@³o¨Ç°t®M¸ê·½»ÝnŪªÌ¦Û¦æ¤U¸ü¡C½Ð¦bµØ³¹¤½¥qºô¯¸¤W·j¯Á¨ì¥»®Ñ¡AµM¦Z³æÀ»¡§¸ê®Æ¤U¸ü¡¨«ö¶s¡A§Y¥i¦b¥»®Ñ¶±¤W§ä¨ì¤U¸üÃì±µ¡C
¥»®ÑŪªÌ¹ï¶H
* ·Q¥þ±¾Ç²ßMySQL§Þ³Nªº¤Hû¡F
* ·QÂà¦æ±q¨Æ¼Æ¾Ú®w¶}µoªº¤Hû¡F
* ¼Æ¾Ú®wºÞ²z¤Hû¡F
* ¼Æ¾Ú®w¹Bºû¤uµ{®v¡F
* §Æ±æ´£°ª¼Æ¾Ú®w¹ê¾Ô¤ô¥ªº¤Hû¡F
* ¼Æ¾Ú®w¶}µo¸g²z¡F
* ¼Æ¾Ú®w¬[ºc®v¡F
* ¬ÛÃö°|®Õªº¾Ç¥Í¡F
* ±M·~°ö°V¾÷ºcªº¾Çû¡F
* »Ýn®É±`¬d¾\MySQL§Þ³N©M¶}µo®×¨Òªº¤Hû¡C
¾\Ū«Øij
* ¤£¨ã³ÆMySQL°ò¦ª¾ÃѪºÅªªÌ¡A«Øij±q²Ä1³¹¶¶¦¸¾\Ū¡A¦}«ö·Ó®Ñ¤¤ªº¾Þ§@¨BÆJ¹ê²{¨C¤@ӮרҡC
* ¦³¤@©wMySQL¶}µo°ò¦ªºÅªªÌ¡A¥i¥H®Ú¾Ú¦Û¨ªº¹ê»Ú±¡ªp¦³¿ï¾Ü¦a¾\Ū¡C
* ®Ñ¤¤ªº¨CӮרҡA¥ý¦Û¦æ«ä¦Ò¦p¦ó¹ê²{¡A¦A¾\Ūµ§ªÌ¤¶²Ðªº¤èªk¡A¥i¥H¹F¨ì¨Æ¥b¥\¿ªº®ÄªG¡C
* ¥ý²z¸Ñ®Ñ¤¤¤¶²Ðªº¬ÛÃö§Þ³Nì²z¡A¦A¿Ë¦Û°Ê¤â¹ê²{¤@¹M®Ñ¤¤ªº®×¨Ò¡A²z¸Ñ·|§ó¥[²`¨è¡C
°É»~»P¤ä«ù
¡@¡@ºÉºÞµ§ªÌ¹ï§Þ³N¦³ªñ¥G§¹¬üªº°l¨D¡A¦ý¬O¥Ñ¤_MySQLÅé¨tÃe¤j¡A©Ò¯A¤Îªºª¾ÃÑÂI²³¦h¡A¤@¥»®Ñ«ÜÃøÁ¿¸Ñ²M·¡©Ò¦³ªºª¾ÃÑÂI¡C¦pªGµ§ªÌ¦³²¨º|¡AÀµ½ÐŪªÌªB¤Í¯à°÷¤Î®É§åµû©M«ü¥¿¡C¦pªG±z¹ï¥»®Ñ¦³¦nªº«Øij©ÎªÌ·Qªk¡A¥i¥H³q¹L¥H¤U¤è¦¡¶i¦æ¤ÏõX¡C ¡@¡@·L«H¤½²³¸¹¡G¦Bªe§Þ³N
PÁÂ
¡@¡@·PÁ©u±Ó¡]ªü¨½¤Ú¤Ú§Þ³N±M®a¡ASeata¶}·½¶µ¥Øµo°_¤H¡^¡B¨v¦t¡]¶}·½²Õ´Dromara³Ð©l¤H¡ASoulºôÃö»PHmily¤À¥¬¦¡¨Æ°È®Ø¬[§@ªÌ¡^¡B¼Bà¡¡]LinuxProbeºô¯¸³Ð©l¤H¡ARHCA¬[ºc®v¡A¹Bºû±M®a¡AºZ¾P®Ñ¡mLinux´N¸Ó³o¤\¾Ç¡n§@ªÌ¡^¡B¨¡ÊN¡]¨¡¹D·½½X§@ªÌ¡^©M¶À¤p¨¸¡]¿ÂÃƪ÷ªA°ª¯Å¶}µo¤uµ{®v¡^¹ï§Ú¼g§@¥»®Ñªº¤j¤O¤ä«ù©MÀ°§U¡I
¡@¡@·PÁ§ڪº¹Î¶¤¦¨û©M³\¦h¤@°_¥æ¬y¹L¤D¦Ü¦X§@¹LªºªB¤ÍÌ¡I
¡@¡@·PÁ§ڪºCSDN³Õ«È¯»µ·¥H¤Î¨º¨Ç¦b§Ú³Õ«È©M¤½²³¸¹¤W¯d¨¥ªºªB¤ÍÌ¡I
¡@¡@·PÁ§ڪº®a¤H¡A¥L̳£¥H¦Û¤vªº¤è¦¡¦b§Ú¼g§@´Á¶¡ÀqÀq¦aµ¹¤©¤ä«ù»P¹ªÀy¡I
¡@¡@·PÁÂ¥Xª©ªÀ°Ñ»P¥»®Ñ¥Xª©ªº¦U¦ì½s¿è¡A¨S¦³§A̪º¨¯¶Ô¤u§@©M¤@µ·¤£ÎAªººë¯«¡A´N¤£·|¦³¥»®Ñªº°ª½è¶q¥Xª©¡C
¡@¡@·PÁ¨ä¥L¤ä«ù¡B¹ªÀy©MÀ°§U¹L§Úªº¤H¡I
¡@¡@³Ì¦Z·PÁÂ¥»®ÑŪªÌ¡A¬O§A̪ºÃ@µ¦¡A¤~Åý§Ú¦³°Ê¤O§¹¦¨¼g§@¥»®Ñªº¡§Á}¥¨¡¨¥ô°È¡I
¡@¡@
¦Bªe |
¤º®e²¤¶¡G¥»®Ñµ²¦X¤j¶q¥Ü¨Ò©M¹ê¾Ô®×¨Ò¡A¥þ±¡B¨t²Î¡B²`¤J¦a¤¶²Ð¤FMySQL¼Æ¾Ú®w§Þ³N¡A«ÂIÄÄz¤FMySQL¶}µo¡BÀu¤Æ©M¹Bºû¹Lµ{¤¤ªº¦UÓ§Þ³NÂI¡C¥»®Ñ¹ï¾Ç²ßMySQL§Þ³N¦³¸û°ªªº°Ñ¦Ò»ùÈ¡A¤×¨ä¬OÀô¹Ò·f«Ø¡BÀu¤Æ¡BºûÅ@©M¬[ºcµ¥¤º®e¥iª½±µ¥Î¤_¹ê»Ú¤u§@¤¤¡C
¥»®Ñ¦@33³¹¡A¤À¬°6½g¡C²Ä1½g¡§MySQL°ò¦¡¨¡A¤¶²Ð¼Æ¾Ú®wªº©w¸q¡Bµo®i¡A¥H¤Î¼Æ¾Ú®w§Þ³N©MMySQL¼Æ¾Ú®wªº¤T¤jS¦¡»P¦sÀx¤ÞÀº¡C²Ä2½g¡§Àô¹Ò·f«Ø¡¨¡A¤¶²ÐVMwareµêÀÀ¾÷¥H¤ÎWindows¡BMac OS X©MCentOS¾Þ§@¨t²Îªº¦w¸Ë¡A¦}¤¶²Ð¦p¦ó¦b¤T¤j¾Þ§@¨t²Î¤W¦w¸Ë©M°t¸mMySQL¡C²Ä3½g¡§MySQL¶}µo¡¨¡A¤¶²ÐMySQL¤¤ªº¼Æ¾Ú®w¾Þ§@¡B¼Æ¾Úªí¾Þ§@¡B¼Æ¾ÚÃþ«¬¡B¹Bºâ²Å¡B¨ç¼Æ¡B¼Æ¾ÚÅܧó¡B¼Æ¾Ú¬d¸ß¡B¯Á¤Þ¡Bµø¹Ï¡B¦sÀx¹Lµ{¡BIJµo¾¹¡B¤À°Ï¡B¤½¥Îªíªí¹F¦¡©M¥Í¦¨¦Cµ¥¡C²Ä4½g¡§MySQLÀu¤Æ¡¨¡A¤¶²ÐMySQL¤¤ªº¬d¸ßÀu¤Æ¡B¯Á¤ÞÀu¤Æ¡BSQL»y¥yÀu¤Æ¡B¼Æ¾Ú®wÀu¤Æ¡BªA°È¾¹Àu¤Æ¡BÀ³¥Îµ{§ÇÀu¤Æ¤Î¨ä¥LÀu¤Æ§Þ³N¡C²Ä5½g¡§MySQLºûÅ@¡¨¡A¤¶²ÐMySQL¤¤¦UºØ©R¥O¦æ¤u¨ãªº¨Ï¥Î¡A¥H¤Î¦UºØ¤é§Óªº¶}±Ò¡B¬d¬Ý¡B§R°£»PÃö³¬¡A¦}¤¶²Ð¼Æ¾Úªº³Æ¥÷»P«ì´_¤ÎMySQL¤¤ªº½ã¤áºÞ²z¡C²Ä6½g¡§MySQL¬[ºc¡¨¡A¤¶²ÐMySQL¤¤ªº´_¨î¡BŪ¼g¤ÀÂ÷Àô¹Ò·f«Ø¡A¥H¤Î¦p¦ó¹ê²{MySQLªº°ª¥i¥Îµ¥¡C
¥»®Ñ¾A¦X·Q¥þ±¾Ç²ßMySQLªº¼Æ¾Ú®wºÞ²z¤Hû¡B¶}µo¤Hû¡B¹Bºû¤uµ{®v©M¬[ºc®v¾\Ū¡A¤]¾A¦X¦U¤j°|®Õªº¾Ç¥Í¤Î¬ÛÃö°ö°V¾÷ºcªº¾Çû¾\Ū¡C¥t¥~¡A¥»®ÑÁÙ«D±`¾A¦X§@¬°¤@¥»®×ÀY¤â¥U¨Ñ¬ÛÃö§Þ³N¤HûÀH¬dÀH¥Î¡C
¥»®Ñ¯S¦â
µøÀW±Ð¾Ç¡G´£¨Ñªñ15¤p®É¡]¦@84¬q¡^°t®M±Ð¾ÇµøÀW¡AÀ°§UŪªÌ´£°ª¾Ç²ß®Ä²v¡C
¤º®e¥þ±¡G²[»\MySQL±q°ò¦¡B¶}µo¡BÀu¤Æ¡A¨ì¹Bºû©M¬[ºcµ¥¤è¤è±±ªºª¾ÃÑÂI¡C
Á¿¸Ñ²`¤J¡G±qMySQL¼Æ¾Ú®wªº°ò¦¾Þ§@¡A¨ìÀu¤Æ¡B¹Bºû»P¬[ºc¡A¼h¼h²`¤J¡C
¹ê¥Î©Ê±j¡Gµ²¦X¤j¶q¸g¨å¥Ü¨Ò©M¹ê¾Ô®×¨Ò®i¶}Á¿¸Ñ¡A±a»âŪªÌ°Ê¤â¹ê½î¡C
°t®M¸ê·½Àò¨ú¤è¦¡
¥»®Ñ¯A¤Îªº·½¥N½X¤Î®×¨Ò¤uµ{¤å¥ó»ÝnŪªÌ¦Û¦æ¤U¸ü¡A½Ð«ö·Ó«e¨¥¤¤ªº¸Ô²Ó»¡©ú¶i¦æÀò¨ú¡C |
¥Ø¿ý¡G«e¨¥ ²Ä1½g MySQL°ò¦ ²Ä1³¹ ¼Æ¾Ú®w·§z 2 1.1 ¼Æ¾Ú®wªº©w¸q 2 1.1.1 ¼Æ¾Ú®w 2 1.1.2 ¼Æ¾Ú®wºÞ²z¨t²Î 2 1.1.3 ¼Æ¾Úªí 3 1.1.4 ¼Æ¾ÚÃþ«¬ 3 1.1.5 ¹Bºâ²Å 4 1.1.6 ¨ç¼Æ 4 1.1.7 ¥DÁä 4 1.1.8 ¥~Áä 4 1.1.9 ¯Á¤Þ 6 1.1.10 µø¹Ï 6 1.1.11 ¦sÀx¹Lµ{ 6 1.1.12 IJµo¾¹ 6 1.1.13 ¦sÀx¤ÞÀº 7 1.2 ¼Æ¾Ú®wªºµo®i 7 1.2.1 ¤H¤uºÞ²z¶¥¬q 7 1.2.2 ¤å¥ó¨t²Î¶¥¬q 7 1.2.3 ¼Æ¾Ú®w¨t²Î¶¥¬q 8 1.2.4 ¤ª¼Æ¾Ú®w¶¥¬q 8 1.3 ¥»³¹Á`µ² 8 ²Ä2³¹ ¼Æ¾Ú®w§Þ³N 9 2.1 ¼Æ¾Ú®w¨t²Î 9 2.2 SQL»y¨¥ 11 2.2.1 SQL»y¨¥¤ÀÃþ 11 2.2.2 ER¹Ï 12 2.2.3 SQL°õ¦æ¬yµ{ 14 2.3 ¼Æ¾Ú®w³X°Ý§Þ³N 15 2.4 ¥»³¹Á`µ² 16 ²Ä3³¹ MySQL¼Æ¾Ú®w 17 3.1 MySQL¤T¤jS¦¡ 17 3.1.1 ²Ä¤@S¦¡ 17 3.1.2 ²Ä¤GS¦¡ 18 3.1.3 ²Ä¤TS¦¡ 19 3.1.4 ¤ÏS¦¡¤Æ 19 3.2 MySQL¦sÀx¤ÞÀº 20 3.2.1 ¬d¬ÝMySQL¤¤ªº¦sÀx¤ÞÀº 20 3.2.2 ±`¥Î¦sÀx¤ÞÀº¤¶²Ð 21 3.3 ¥»³¹Á`µ² 23 ²Ä2½g Àô¹Ò·f«Ø ²Ä4³¹ ¦w¸Ë¤T¤j¾Þ§@¨t²Î 26 4.1 ¦w¸ËVMwareµêÀÀ¾÷ 26 4.1.1 ¤U¸üVMwareµêÀÀ¾÷ 26 4.1.2 ¦w¸ËVMwareµêÀÀ¾÷¨BÆJ 30 4.2 ¦w¸ËWindows¾Þ§@¨t²Î 31 4.2.1 ¤U¸üWindows¾Þ§@¨t²Î 31 4.2.2 ³]¸mVMwareµêÀÀ¾÷ 33 4.2.3 ¦w¸ËWindows¾Þ§@¨t²Î¨BÆJ 38 4.3 ¦w¸ËMac OS X¾Þ§@¨t²Î 44 4.3.1 ³]¸mVMwareµêÀÀ¾÷ 45 4.3.2 ¦w¸ËMac OS X¾Þ§@¨t²Î¨BÆJ 46 4.4 ¦w¸ËCentOS¾Þ§@¨t²Î 55 4.4.1 ¤U¸üCentOS¾Þ§@¨t²Î 55 4.4.2 ³]¸mVMwareµêÀÀ¾÷ 56 4.4.3 ¦w¸ËCentOS¾Þ§@¨t²Î¨BÆJ 56 4.5 ¥»³¹Á`µ² 65 ²Ä5³¹ ªA°È¾¹°ò¦°t¸m 66 5.1 °t¸mCentOS 6.8ªA°È¾¹Àô¹Ò 66 5.1.1 קï¥D¾÷¦W 66 5.1.2 °t¸mÀRºAIP¦a§} 69 5.1.3 °t¸m¥D¾÷¦W©MIP¦a§}ªº¬M®gÃö¨t 71 5.1.4 °t¸m¨¾¤õùÙ³W«h 71 5.1.5 °t¸mroot¥Î¤áSSH§K±K½Xµn¿ý 73 5.2 ²K¥[mysql¥Î¤á¨¥÷ 75 5.2.1 ²K¥[mysql¥Î¤á²Õ©M¥Î¤á 75 5.2.2 ½á¤©mysql¥Î¤á¥Ø¿ýÅv 75 5.2.3 ½á¤©mysql¥Î¤ásudoÅv 76 5.2.4 ½á¤©mysql¥Î¤áµn¿ý±K½X 76 5.2.5 °t¸mmysql¥Î¤áSSH§K±K½Xµn¿ý 76 5.3 ¥»³¹Á`µ² 77 ²Ä6³¹ ·f«ØMySQLÀô¹Ò 78 6.1 °ò¤_MSI¤å¥ó¦w¸ËWindowsª©¥»ªºMySQL 78 6.1.1 ¤U¸üMySQLªºMSI¦w¸Ë¥] 78 6.1.2 °ò¤_MSI¤å¥ó¦w¸ËMySQL 80 6.1.3 °t¸mMySQL¨t²ÎÀô¹ÒÅܶq 90 6.1.4 ´ú¸ÕMySQL 92 6.2 °ò¤_ZIP¤å¥ó¦w¸ËWindowsª©¥»ªºMySQL 92 6.2.1 ¤U¸üMySQLªºZIP¦w¸Ë¥] 92 6.2.2 °ò¤_ZIP¤å¥ó¦w¸ËMySQL 94 6.2.3 °t¸mMySQL¨t²ÎÀô¹ÒÅܶq 96 6.2.4 ´ú¸ÕMySQL 97 6.3 °ò¤_DMG¤å¥ó¦w¸ËMac OS Xª©¥»ªºMySQL 98 6.3.1 ¤U¸üMySQLªºDMG¦w¸Ë¥] 98 6.3.2 °ò¤_DMG¤å¥ó¦w¸ËMySQL 100 6.3.3 °t¸mMySQL¨t²ÎÀô¹ÒÅܶq 102 6.3.4 ´ú¸ÕMySQL 104 6.4 °ò¤_GZ¤å¥ó¦w¸ËMac OS Xª©¥»ªºMySQL 105 6.4.1 ¤U¸üMySQLªºGZ¦w¸Ë¥] 105 6.4.2 °ò¤_GZ¤å¥ó¦w¸ËMySQL 105 6.4.3 °t¸mMySQL¨t²ÎÀô¹ÒÅܶq 107 6.4.4 ´ú¸ÕMySQL 107 6.5 °ò¤_RPM¤å¥ó¦w¸ËCentOSª©¥»ªºMySQL 109 6.5.1 §R°£CentOS 6.8ªA°È¾¹¦Û±aªºMySQL 109 6.5.2 ¤U¸üMySQLªºRPM¦w¸Ë¥] 110 6.5.3 °ò¤_RPM¤å¥ó¦w¸ËMySQL 111 6.5.4 ´ú¸ÕMySQL 113 6.6 °ò¤_·½½X¦w¸ËCentOSª©¥»ªºMySQL 114 6.6.1 Àô¹Ò·Ç³Æ 115 6.6.2 ¤U¸ü³n¥ó¥] 116 6.6.3 ¤É¯Ågcc©Mcmake 117 6.6.4 ½sĶ¦w¸ËMySQL·½½X 119 6.6.5 °t¸mMySQL 120 6.6.6 ªì©l¤Æ¦}±Ò°ÊMySQLªA°È 123 6.6.7 ´ú¸ÕMySQL 123 6.6.8 ½sĶ¦w¸ËMySQLªºboost·½½X 124 6.7 ¹J¨ìªº°ÝÃD©M¸Ñ¨M¤è®× 125 6.8 ¥»³¹Á`µ² 126 ²Ä3½g MySQL¶}µo ²Ä7³¹ MySQL¾Þ§@¼Æ¾Ú®w 128 7.1 ³Ð«Ø¼Æ¾Ú®w 128 7.1.1 ¨Ï¥ÎCREATE DATABASE»y¥y³Ð«Ø¼Æ¾Ú®w 128 7.1.2 ¨Ï¥ÎCREATE DATABASE IF NOT EXISTS»y¥y³Ð«Ø¼Æ¾Ú®w 129 7.2 ¬d¬Ý¼Æ¾Ú®w 130 7.2.1 ¬d¬ÝMySQL¤¤¦s¦bªº¼Æ¾Ú®w 130 7.2.2 ¬d¬ÝMySQL©R¥O¦æ©Ò¦bªº¼Æ¾Ú®w 131 7.2.3 ¬d¬Ý¼Æ¾Ú®wªº³Ð«Ø«H®§ 131 7.3 קï¼Æ¾Ú®w¦WºÙ 132 7.3.1 ³q¹L«©R¦W¼Æ¾Úªíקï¼Æ¾Ú®w¦WºÙ 132 7.3.2 ³q¹L¾É¤J/¾É¥X¼Æ¾Úקï¼Æ¾Ú®w¦WºÙ 133 7.3.3 ³q¹L³Ð«Ø¼Æ¾Úªíקï¼Æ¾Ú®w¦WºÙ 134 7.4 ¼Æ¾Ú®w½s½X 135 7.4.1 ³Ð«Ø¼Æ¾Ú®w®É«ü©w¦r²Å½s½X 135 7.4.2 קï¼Æ¾Ú®wªº¦r²Å½s½X 136 7.5 §R°£¼Æ¾Ú®w 136 7.6 ¥»³¹Á`µ² 137 ²Ä8³¹ MySQL¾Þ§@¼Æ¾Úªí 138 8.1 ³Ð«Ø¼Æ¾Úªí 138 8.1.1 ³Ð«ØªÅ¼Æ¾Úªí 138 8.1.2 ³Ð«Ø¼Æ¾Úªí®É«ü©w¥DÁä 141 8.1.3 ³Ð«Ø¼Æ¾Úªí®É«ü©w¥~Áä 142 8.1.4 ³Ð«Ø¼Æ¾Úªí®É«ü©w¦r¬q«DªÅ 144 8.1.5 ³Ð«Ø¼Æ¾Úªí®É«ü©wÀq»{È 144 8.1.6 ³Ð«Ø¼Æ¾Úªí®É«ü©w¥DÁäÀq»{»¼¼W 145 8.1.7 ³Ð«Ø¼Æ¾Úªí®É«ü©w¦sÀx¤ÞÀº 146 8.1.8 ³Ð«Ø¼Æ¾Úªí®É«ü©w½s½X 146 8.2 ¬d¬Ý¼Æ¾Úªíµ²ºc 147 8.2.1 ¨Ï¥ÎDESCRIBE/DESC»y¥y¬d¬Ýªíµ²ºc 147 8.2.2 ¨Ï¥ÎSHOW CREATE TABLE»y¥y¬d¬Ýªíµ²ºc 148 8.3 קï¼Æ¾Úªí 149 8.3.1 קï¼Æ¾Úªí¦WºÙ 150 8.3.2 ²K¥[¦r¬q 150 8.3.3 ²K¥[¦r¬q®É«ü©w¦ì¸m 151 8.3.4 קï¦r¬q¦WºÙ 153 8.3.5 קï¦r¬qªº¼Æ¾ÚÃþ«¬ 154 8.3.6 קï¦r¬qªº¦ì¸m 154 8.3.7 §R°£¦r¬q 156 8.3.8 קï¤w¦³ªíªº¦sÀx¤ÞÀº 157 8.3.9 ¨ú®ø¼Æ¾Úªíªº¥~Áä¬ù§ô 158 8.4 §R°£¼Æ¾Úªí 158 8.4.1 §R°£¨S¦³ÃöÁpÃö¨tªº¼Æ¾Úªí 158 8.4.2 §R°£¦³¥~Áä¬ù§ôªº¥Dªí 160 8.5 MySQL¤¤ªºÁ{®Éªí 160 8.5.1 ³Ð«ØÁ{®Éªí 161 8.5.2 §R°£Á{®Éªí 161 8.6 ¥»³¹Á`µ² 162 ²Ä9³¹ MySQL¼Æ¾ÚÃþ«¬ 163 9.1 ¼ÆÈÃþ«¬ 163 9.1.1 ¾ã¼ÆÃþ«¬ 163 9.1.2 ¯BÂI¼ÆÃþ«¬ 168 9.1.3 ©wÂI¼ÆÃþ«¬ 171 9.2 ¤é´Á©M®É¶¡Ãþ«¬ 173 9.2.1 YEARÃþ«¬ 174 9.2.2 TIMEÃþ«¬ 176 9.2.3 DATEÃþ«¬ 178 9.2.4 DATETIMEÃþ«¬ 181 9.2.5 TIMESTAMPÃþ«¬ 183 9.3 ¤å¥»¦r²Å¦êÃþ«¬ 186 9.3.1 ¤å¥»¦r²Å¦êÃþ«¬·§z 186 9.3.2 CHAR»PVARCHARÃþ«¬ 187 9.3.3 TEXTÃþ«¬ 188 9.3.4 ENUMÃþ«¬ 189 9.3.5 SETÃþ«¬ 191 9.3.6 JSONÃþ«¬ 192 9.4 ¤G¶i¨î¦r²Å¦êÃþ«¬ 193 9.4.1 ¤G¶i¨î¦r²Å¦êÃþ«¬·§z 193 9.4.2 BITÃþ«¬ 194 9.4.3 BINARY»PVARBINARYÃþ«¬ 195 9.4.4 BLOBÃþ«¬ 196 9.5 ¥»³¹Á`µ² 196 ²Ä10³¹ MySQL¹Bºâ²Å 197 10.1 ºâ³N¹Bºâ²Å 197 10.1.1 MySQL¤ä«ùªººâ³N¹Bºâ²Å 197 10.1.2 ºâ³N¹Bºâ²Å²³æ¥Ü¨Ò 198 10.2 ¤ñ¸û¹Bºâ²Å 199 10.2.1 MySQL¤ä«ùªº¤ñ¸û¹Bºâ²Å 199 10.2.2 ¤ñ¸û¹Bºâ²Å²³æ¥Ü¨Ò 201 10.3 ÅÞ¿è¹Bºâ²Å 206 10.3.1 MySQL¤ä«ùªºÅÞ¿è¹Bºâ²Å 206 10.3.2 ÅÞ¿è¹Bºâ²Å²³æ¥Ü¨Ò 206 10.4 ¦ì¹Bºâ²Å 208 10.4.1 MySQL¤ä«ùªº¦ì¹Bºâ²Å 208 10.4.2 ¦ì¹Bºâ²Å²³æ¥Ü¨Ò 208 10.5 ¹Bºâ²ÅªºÀu¥ý¯Å 210 10.6 ¥»³¹Á`µ² 211 ²Ä11³¹ MySQL¨ç¼Æ 212 11.1 MySQL¨ç¼Æ²¤¶ 212 11.2 ¼Æ¾Ç¨ç¼Æ 213 11.2.1 µ´¹ïȨç¼Æ 213 11.2.2 ¶ê©P²v¨ç¼Æ 213 11.2.3 Àò¨ú¾ã¼Æªº¨ç¼Æ 213 11.2.4 ªð¦^¦Cªí¤¤ªº³Ì¤jÈ»P³Ì¤pȨç¼Æ 214 11.2.5 ¨¤«×»P©·«×¤¬´«¨ç¼Æ 215 11.2.6 ¤T¨¤¨ç¼Æ 215 11.2.7 ¼¤è»P¶}¤è¨ç¼Æ 217 11.2.8 ¹ï¼Æ¨ç¼Æ 218 11.2.9 ÀH¾÷¨ç¼Æ 219 11.2.10 ¥|ªÙ¤¤J»P¼Æ¦rºI¨ú¨ç¼Æ 220 11.2.11 ²Å¸¹¨ç¼Æ 221 11.2.12 ¼Æ¾Ç¹Bºâ¨ç¼Æ 221 11.3 ¦r²Å¦ê¨ç¼Æ 222 11.3.1 ASCII(S)¨ç¼Æ 222 11.3.2 CHAR_LENGTH(S)¨ç¼Æ 222 11.3.3 LENGTH(S)¨ç¼Æ 223 11.3.4 CONCAT(S1,S2,¡K,Sn)¨ç¼Æ 223 11.3.5 CONCAT_WS(X, S1,S2,¡K,Sn)¨ç¼Æ 223 11.3.6 INSERT(oldstr, x, y, replacestr)¨ç¼Æ 224 11.3.7 LOWER(S)¨ç¼Æ 224 11.3.8 UPPER(S)¨ç¼Æ 225 11.3.9 LEFT(str, x)¨ç¼Æ 225 11.3.10 RIGHT(str, x)¨ç¼Æ 225 11.3.11 LPAD(str, n pstr)¨ç¼Æ 226 11.3.12 RPAD(str, n, pstr)¨ç¼Æ 226 11.3.13 LTRIM(S)¨ç¼Æ 226 11.3.14 RTRIM(S)¨ç¼Æ 226 11.3.15 TRIM(S)¨ç¼Æ 227 11.3.16 TRIM(substr FROM str)¨ç¼Æ 227 11.3.17 REPEAT(str, x)¨ç¼Æ 227 11.3.18 REPLACE(S,A,B)¨ç¼Æ 227 11.3.19 STRCMP(S1, S2)¨ç¼Æ 228 11.3.20 SUBSTR(S, X, Y)¨ç¼Æ 228 11.3.21 MID(S, X, Y)¨ç¼Æ 228 11.3.22 SPACE(X)¨ç¼Æ 229 11.3.23 LOCATE(substr, str)¨ç¼Æ 229 11.3.24 ELT(M, S1, S2, ¡K, Sn)¨ç¼Æ 230 11.3.25 FIELD(S,S1,S2,¡K,Sn)¨ç¼Æ 230 11.3.26 FIND_IN_SET(S1, S2)¨ç¼Æ 230 11.3.27 REVERSE(S)¨ç¼Æ 231 11.3.28 NULLIF(value1, value2)¨ç¼Æ 231 11.4 ¤é´Á©M®É¶¡¨ç¼Æ 231 11.4.1 CURDATE()¨ç¼Æ 232 11.4.2 CURTIME()¨ç¼Æ 232 11.4.3 NOW()¨ç¼Æ 232 11.4.4 UNIX_TIMESTAMP(date)¨ç¼Æ 233 11.4.5 FROM_UNIXTIME(timestamp)¨ç¼Æ 233 11.4.6 UTC_DATE()¨ç¼Æ 233 11.4.7 UTC_TIME()¨ç¼Æ 234 11.4.8 YEAR(date)¨ç¼Æ 234 11.4.9 MONTH(date)¨ç¼Æ 234 11.4.10 MONTHNAME(date)¨ç¼Æ 235 11.4.11 DAY(date)¨ç¼Æ 235 11.4.12 DAYNAME(date)¨ç¼Æ 235 11.4.13 DAYOFWEEK(date)¨ç¼Æ 235 11.4.14 WEEKDAY(date)¨ç¼Æ 236 11.4.15 WEEK(date)¨ç¼Æ 236 11.4.16 WEEKOFYEAR(date)¨ç¼Æ 236 11.4.17 DAYOFYEAR(date)¨ç¼Æ 237 11.4.18 DAYOFMONTH(date)¨ç¼Æ 237 11.4.19 QUARTER(date)¨ç¼Æ 237 11.4.20 HOUR(time)¨ç¼Æ 237 11.4.21 MINUTE(time)¨ç¼Æ 238 11.4.22 SECOND(time)¨ç¼Æ 238 11.4.23 EXTRACT(type FROM date)¨ç¼Æ 238 11.4.24 TIME_TO_SEC(time)¨ç¼Æ 239 11.4.25 SEC_TO_TIME(seconds)¨ç¼Æ 240 11.4.26 DATE_ADD(date, INTERVAL expr type)¨ç¼Æ 240 11.4.27 DATE_SUB(date, INTERVAL expr type)¨ç¼Æ 241 11.4.28 ADDTIME(time1, time2)¨ç¼Æ 241 11.4.29 SUBTIME(time1, time2)¨ç¼Æ 242 11.4.30 DATEDIFF(date1, date2)¨ç¼Æ 242 11.4.31 FROM_DAYS(N)¨ç¼Æ 242 11.4.32 LAST_DAY(date)¨ç¼Æ 243 11.4.33 MAKEDATE(year, n)¨ç¼Æ 243 11.4.34 MAKETIME(hour, minute, second)¨ç¼Æ 243 11.4.35 PERIOD_ADD(time, n)¨ç¼Æ 244 11.4.36 TO_DAYS(date)¨ç¼Æ 244 11.4.37 DATE_FORMAT(date, format)¨ç¼Æ 244 11.4.38 TIME_FORMAT(time, format)¨ç¼Æ 245 11.4.39 GET_FORMAT(date_type, format_type)¨ç¼Æ 246 11.4.40 STR_TO_DATE(str, format)¨ç¼Æ 246 11.5 ¬yµ{³B²z¨ç¼Æ 247 11.5.1 IF(value, value1,value2)¨ç¼Æ 247 11.5.2 IFNULL(value1, value2)¨ç¼Æ 247 11.5.3 CASE WHEN THEN¨ç¼Æ 247 11.5.4 CASE expr WHEN¨ç¼Æ 248 11.6 ¥[±K»P¸Ñ±K¨ç¼Æ 248 11.6.1 PASSWORD(value)¨ç¼Æ 249 11.6.2 MD5(value)¨ç¼Æ 249 11.6.3 ENCODE(value, password_seed)¨ç¼Æ 249 11.6.4 DECODE(value, password_seed)¨ç¼Æ 249 11.7 »E¦X¨ç¼Æ 250 11.7.1 COUNT(*/¦r¬q¦WºÙ)¨ç¼Æ 250 11.7.2 MAX(¦r¬q¦WºÙ)¨ç¼Æ 251 11.7.3 MIN(¦r¬q¦WºÙ)¨ç¼Æ 251 11.7.4 SUM(¦r¬q¦WºÙ)¨ç¼Æ 251 11.7.5 AVG(¦r¬q¦WºÙ)¨ç¼Æ 251 11.8 Àò¨úMySQL«H®§¨ç¼Æ 252 11.8.1 VERSION()¨ç¼Æ 252 11.8.2 CONNECTION_ID()¨ç¼Æ 252 11.8.3 DATABASE()¨ç¼Æ 252 11.8.4 USER()¨ç¼Æ 253 11.8.5 LAST_INSERT_ID()¨ç¼Æ 253 11.8.6 CHARSET(value)¨ç¼Æ 254 11.8.7 COLLATION(value)¨ç¼Æ 254 11.9 ¥[Âê»P¸ÑÂê¨ç¼Æ 254 11.9.1 GET_LOCK(value, timeout)¨ç¼Æ 254 11.9.2 RELEASE_LOCK(value)¨ç¼Æ 255 11.9.3 IS_FREE_LOCK(value)¨ç¼Æ 255 11.9.4 IS_USED_LOCK(value)¨ç¼Æ 255 11.10 JSON¨ç¼Æ 256 11.10.1 JSON_CONTAINS(json_doc, value)¨ç¼Æ 256 11.10.2 JSON_SEARCH(json_doc ->> $[*].key, type, value)¨ç¼Æ 257 11.10.3 JSON_PRETTY(json_doc)¨ç¼Æ 257 11.10.4 JSON_DEPTH(json_doc)¨ç¼Æ 257 11.10.5 JSON_LENGTH(json_doc[, path])¨ç¼Æ 258 11.10.6 JSON_KEYS(json_doc[, path])¨ç¼Æ 258 11.10.7 JSON_INSERT(json_doc, path, val[, path, val] ...)¨ç¼Æ 258 11.10.8 JSON_REMOVE(json_doc, path[, path] ...)¨ç¼Æ 259 11.10.9 JSON_REPLACE(json_doc, path, val[, path, val] ...)¨ç¼Æ 259 11.10.10 JSON_SET(json_doc, path, val[, path, val] ...)¨ç¼Æ 260 11.10.11 JSON_TYPE(json_val)¨ç¼Æ 261 11.10.12 JSON_VALID(value)¨ç¼Æ 261 11.11 µ¡¤f¨ç¼Æ 261 11.11.1 §Ç¸¹¨ç¼Æ 263 11.11.2 ¤À¥¬¨ç¼Æ 264 11.11.3 «e¦Z¨ç¼Æ 265 11.11.4 º§À¨ç¼Æ 267 11.11.5 ¨ä¥L¨ç¼Æ 268 11.12 MySQLªº¨ä¥L¨ç¼Æ 269 11.12.1 FORMAT(value, n)¨ç¼Æ 269 11.12.2 CONV(value, from, to)¨ç¼Æ 269 11.12.3 INET_ATON(value)¨ç¼Æ 270 11.12.4 INET_NTOA(value)¨ç¼Æ 270 11.12.5 BENCHMARK(n, expr)¨ç¼Æ 270 11.12.6 CAST(value AS type)¨ç¼Æ 271 11.12.7 CONVERT(value USING char_code)¨ç¼Æ 271 11.13 ¥»³¹Á`µ² 272 ²Ä12³¹ MySQL¼Æ¾ÚÅܧó 273 12.1 ¼Æ¾Ú´¡¤J 273 12.1.1 ¼Æ¾Ú´¡¤J³W«h 273 12.1.2 ´¡¤J§¹¾ãªº¦æ°O¿ý 274 12.1.3 «ü©w¦r¬q´¡¤J¼Æ¾Ú 275 12.1.4 ¤@¦¸´¡¤J¦h±ø¼Æ¾Ú°O¿ý 276 12.1.5 ±N¬d¸ßµ²ªG´¡¤J¥t¤@Óªí¤¤ 278 12.2 ¼Æ¾Ú§ó·s 280 12.2.1 §ó·s¼Æ¾Úªí¤¤ªº©Ò¦³°O¿ý 281 12.2.2 §ó·sªí¤¤¯S©wªº¼Æ¾Ú¦æ 281 12.2.3 §ó·s¬YÓS³ò¤ºªº¼Æ¾Ú 282 12.2.4 §ó·s²Å¦X¥¿«hªí¹F¦¡ªº¼Æ¾Ú 285 12.3 ¼Æ¾Ú§R°£ 286 12.3.1 §R°£¼Æ¾Úªí¤¤¯S©wªº¼Æ¾Ú 286 12.3.2 §R°£¬YÓS³ò¤ºªº¼Æ¾Ú 286 12.3.3 §R°£²Å¦X¥¿«hªí¹F¦¡ªº¼Æ¾Ú 289 12.3.4 §R°£¼Æ¾Úªí¤¤ªº©Ò¦³¼Æ¾Ú 289 12.4 ¥»³¹Á`µ² 289 ²Ä13³¹ MySQL¼Æ¾Ú¬d¸ß 290 13.1 ¼Æ¾Ú·Ç³Æ 290 13.2 SELECT¬d¸ß»y¥y 291 13.2.1 ¬d¸ßªí¤¤©Ò¦³¦r¬qªº¼Æ¾Ú 291 13.2.2 ¬d¸ßªí¤¤³æÓ¦r¬qªº¼Æ¾Ú 293 13.2.3 ¬d¸ßªí¤¤«ü©w¦r¬qªº¼Æ¾Ú 294 13.2.4 ¨Ï¥Î§¹¥þ©w¦r¬q¦W¬d¸ß¼Æ¾Ú 294 13.2.5 ¨Ï¥Î§¹¥þ©wªí¦W¬d¸ß¼Æ¾Ú 295 13.3 WHERE±ø¥ó»y¥y 296 13.3.1 WHERE»y¥y»yªk®æ¦¡ 296 13.3.2 ¬d¸ß³æ¤@ªº¯S©w¼Æ¾Ú 296 13.3.3 ¬d¸ß¬YÓS³ò¤ºªº¼Æ¾Ú 297 13.3.4 IN©MNOT IN±ø¥ó»y¥y 297 13.3.5 BETWEEN AND±ø¥ó»y¥y 298 13.3.6 LIKE±ø¥ó»y¥y 299 13.3.7 ªÅȱø¥ó¨î»y¥y 300 13.3.8 AND»y¥y 302 13.3.9 OR»y¥y 303 13.3.10 DISTINCT»y¥y 303 13.3.11 ORDER BY»y¥y 304 13.3.12 GROUP BY»y¥y 306 13.3.13 HAVING»y¥y 308 13.3.14 WITH ROLLUP»y¥y 308 13.3.15 ¹ï¼Æ¾Ú¦P®É¶i¦æ¤À²Õ»P±Æ§Ç 308 13.3.16 LIMIT»y¥y 309 13.4 ¼Æ¾Ú»E¦X¬d¸ß 310 13.4.1 ¬d¸ß¼Æ¾ÚªºÁ`¦æ¼Æ 310 13.4.2 ¬d¸ß¬Y¦C¼Æ¾ÚªºÁ`©M 311 13.4.3 ¬d¸ß¬Y¦C¼Æ¾Úªº³Ì¤pÈ 312 13.4.4 ¬d¸ß¬Y¦C¼Æ¾Úªº³Ì¤jÈ 312 13.4.5 ¬d¸ß¬Y¦C¼Æ¾Úªº¥§¡È 313 13.5 JOIN»y¥y 314 13.5.1 INNER JOIN»y¥y 314 13.5.2 LEFT JOIN»y¥y 315 13.5.3 RIGHT JOIN»y¥y 316 13.5.4 CROSS JOIN »y¥y 317 13.5.5 ¨Ï¥Î´_¦X³s±µ±ø¥ó¬d¸ß¼Æ¾Ú 317 13.6 ¤l¬d¸ß»y¥y 318 13.6.1 ANY¤l¬d¸ß 318 13.6.2 ALL¤l¬d¸ß 319 13.6.3 EXISTS¤l¬d¸ß 319 13.6.4 NOT EXISTS¤l¬d¸ß 320 13.6.5 IN¤l¬d¸ß 320 13.6.6 NOT IN¤l¬d¸ß 321 13.6.7 ¤l¬d¸ß§@¬°µ²ªG¦r¬q 321 13.7 UNIONÁp¦X»y¥y 322 13.7.1 UNION»y¥y 322 13.7.2 UNION ALL»y¥y 323 13.8 ¨Ï¥Î§O¦W¬d¸ß¼Æ¾Ú 323 13.8.1 ¬°¦r¬q¦W«ü©w§O¦W 323 13.8.2 ¬°ªí¦W«ü©w§O¦W 324 13.8.3 ¦P®É¬°¦r¬q¦W©Mªí¦W«ü©w§O¦W 325 13.9 ¨Ï¥Î¥¿«hªí¹F¦¡¬d¸ß¼Æ¾Ú 325 13.10 ¥»³¹Á`µ² 326 ²Ä14³¹ MySQL¯Á¤Þ 327 14.1 ¯Á¤Þ²¤¶ 327 14.1.1 MySQL¹M¾úªíªº¤è¦¡ 327 14.1.2 ¯Á¤ÞªºÀuÂI»P¯ÊÂI 328 14.1.3 ¯Á¤Þªº³Ð«Øì«h 328 14.2 ¯Á¤Þªº¨Ï¥Î³õ´º 329 14.2.1 ¾A¦X³Ð«Ø¯Á¤Þªº³õ´º 329 14.2.2 ¤£¾A¦X³Ð«Ø¯Á¤Þªº³õ´º 330 14.3 ³Ð«Ø¼Æ¾Úªí®É³Ð«Ø¯Á¤Þ 330 14.3.1 »yªk®æ¦¡ 330 14.3.2 ³Ð«Ø´¶³q¯Á¤Þ 331 14.3.3 ³Ð«Ø°ß¤@¯Á¤Þ 332 14.3.4 ³Ð«Ø¥DÁä¯Á¤Þ 333 14.3.5 ³Ð«Ø³æ¦C¯Á¤Þ 333 14.3.6 ³Ð«Ø²Õ¦X¯Á¤Þ 334 14.3.7 ³Ð«Ø¥þ¤å¯Á¤Þ 337 14.3.8 ³Ð«ØªÅ¶¡¯Á¤Þ 338 14.4 ¬°¤w¦³¼Æ¾Úªí²K¥[¯Á¤Þ 338 14.4.1 »yªk®æ¦¡ 339 14.4.2 ³Ð«Ø´¶³q¯Á¤Þ 339 14.4.3 ³Ð«Ø°ß¤@¯Á¤Þ 340 14.4.4 ³Ð«Ø¥DÁä¯Á¤Þ 341 14.4.5 ³Ð«Ø³æ¦C¯Á¤Þ 342 14.4.6 ³Ð«Ø²Õ¦X¯Á¤Þ 343 14.4.7 ³Ð«Ø¥þ¤å¯Á¤Þ 344 14.4.8 ³Ð«ØªÅ¶¡¯Á¤Þ 345 14.5 §R°£¯Á¤Þ 347 14.5.1 »yªk®æ¦¡ 347 14.5.2 §R°£¯Á¤Þ¤è¦¡ 347 14.6 ÁôÂïÁ¤Þ 348 14.6.1 ÁôÂïÁ¤Þ·§z 349 14.6.2 »yªk®æ¦¡ 349 14.6.3 ³Ð«Ø´ú¸Õªí 349 14.6.4 ¯Á¤Þ¾Þ§@ 350 14.7 °§Ç¯Á¤Þ 355 14.7.1 °§Ç¯Á¤Þ·§z 355 14.7.2 °§Ç¯Á¤Þ¾Þ§@ 355 14.8 ¨ç¼Æ¯Á¤Þ 359 14.8.1 ¨ç¼Æ¯Á¤Þ·§z 359 14.8.2 ¨ç¼Æ¯Á¤Þ¾Þ§@ 359 14.9 ¥»³¹Á`µ² 363 ²Ä15³¹ MySQLµø¹Ï 364 15.1 µø¹Ï·§z 364 15.1.1 µø¹Ïªº·§©À 364 15.1.2 µø¹ÏªºÀuÂI 364 15.2 ³Ð«Øµø¹Ï 365 15.2.1 »yªk®æ¦¡ 365 15.2.2 ³Ð«Ø³æªíµø¹Ï 366 15.2.3 ³Ð«Ø¦hªíÁp¦Xµø¹Ï 369 15.3 ¬d¬Ýµø¹Ï 370 15.3.1 ¨Ï¥ÎSHOW TABLES»y¥y¬d¬Ýµø¹Ï 370 15.3.2 ¨Ï¥ÎDESCRIBE/DESC»y¥y¬d¬Ýµø¹Ï 371 15.3.3 ¨Ï¥ÎSHOW TABLE STATUS»y¥y¬d¬Ýµø¹Ï 371 15.3.4 ¨Ï¥ÎSHOW CREATE VIEW»y¥y¬d¬Ýµø¹Ï 373 15.3.5 ¬d¬Ýviews¼Æ¾Úªí¤¤ªºµø¹Ï«H®§ 373 15.4 קïµø¹Ïªºµ²ºc 374 15.4.1 ¨Ï¥ÎCREATE OR REPLACE VIEW»y¥yקïµø¹Ïµ²ºc 374 15.4.2 ¨Ï¥ÎALTER»y¥yקïµø¹Ïµ²ºc 375 15.5 §ó·sµø¹Ïªº¼Æ¾Ú 376 15.5.1 ª½±µ§ó·sµø¹Ï¼Æ¾Ú 376 15.5.2 ¶¡±µ§ó·sµø¹Ï¼Æ¾Ú 379 15.6 §R°£µø¹Ï 381 15.7 ¥»³¹Á`µ² 382 ²Ä16³¹ ¦sÀx¹Lµ{©M¨ç¼Æ 383 16.1 ¦sÀx¹Lµ{©M¨ç¼Æ²¤¶ 383 16.1.1 ¤°¤\¬O¦sÀx¹Lµ{©M¨ç¼Æ 383 16.1.2 ¦sÀx¹Lµ{©M¨ç¼Æªº¨Ï¥Î³õ´º 384 16.1.3 ¦sÀx¹Lµ{©M¨ç¼ÆªºÀuÂI 384 16.2 ³Ð«Ø¦sÀx¹Lµ{©M¨ç¼Æ 386 16.2.1 ³Ð«Ø¦sÀx¹Lµ{ 386 16.2.2 ³Ð«Ø¦sÀx¨ç¼Æ 388 16.3 ¬d¬Ý¦sÀx¹Lµ{©M¨ç¼Æ 389 16.3.1 ¬d¬Ý¦sÀx¹Lµ{©M¨ç¼Æªº³Ð«Ø©Î©w¸q«H®§ 389 16.3.2 ¬d¬Ý¦sÀx¹Lµ{©M¨ç¼Æªºª¬ºA«H®§ 390 16.3.3 ±q¼Æ¾Ú®w¤¤¬d¬Ý¦sÀx¹Lµ{©M¨ç¼Æªº«H®§ 391 16.4 קï¦sÀx¹Lµ{©M¨ç¼Æ 394 16.4.1 קï¦sÀx¹Lµ{ 394 16.4.2 קï¦sÀx¨ç¼Æ 395 16.5 ½Õ¥Î¦sÀx¹Lµ{©M¨ç¼Æ 396 16.5.1 ½Õ¥Î¦sÀx¹Lµ{ 396 16.5.2 ½Õ¥Î¦sÀx¨ç¼Æ 397 16.6 §R°£¦sÀx¹Lµ{©M¨ç¼Æ 398 16.6.1 §R°£¦sÀx¹Lµ{ 398 16.6.2 §R°£¦sÀx¨ç¼Æ 398 16.7 MySQL¤¤¨Ï¥ÎÅܶq 399 16.7.1 ©w¸qÅܶq 399 16.7.2 Åܶq½áÈ 400 16.8 MySQL¤¤¨Ï¥ÎÅܶq®×¨Ò 401 16.8.1 ¦b¦sÀx¹Lµ{¤¤¨Ï¥ÎÅܶq 401 16.8.2 ¦b¨ç¼Æ¤¤¨Ï¥ÎÅܶq 402 16.9 ©w¸q±ø¥ó©M³B²zµ{§Ç 403 16.9.1 ©w¸q±ø¥ó 403 16.9.2 ©w¸q³B²zµ{§Ç 404 16.10 ©w¸q±ø¥ó©M³B²zµ{§Ç®×¨Ò 405 16.10.1 ¦b¦sÀx¹Lµ{¤¤¥¼©w¸q±ø¥ó©M³B²zµ{§Ç 406 16.10.2 ¦b¦sÀx¹Lµ{¤¤©w¸q±ø¥ó©M³B²zµ{§Ç 407 16.10.3 ¦b¨ç¼Æ¤¤¥¼©w¸q±ø¥ó©M³B²zµ{§Ç 408 16.10.4 ¦b¨ç¼Æ¤¤©w¸q±ø¥ó©M³B²zµ{§Ç 409 16.11 MySQL¤¤´å¼Ðªº¨Ï¥Î 410 16.11.1 Án©ú´å¼Ð 410 16.11.2 ¥´¶}´å¼Ð 410 16.11.3 ¨Ï¥Î´å¼Ð 411 16.11.4 Ãö³¬´å¼Ð 411 16.12 MySQL¤¤´å¼Ðªº¨Ï¥Î®×¨Ò 412 16.12.1 ¦b¦sÀx¹Lµ{¤¤¨Ï¥Î´å¼Ð 412 16.12.2 ¦b¨ç¼Æ¤¤¨Ï¥Î´å¼Ð 413 16.13 MySQL¤¤±±¨î¬yµ{ªº¨Ï¥Î 414 16.13.1 ¨Ï¥ÎIF»y¥y±±¨î¬yµ{ 414 16.13.2 ¨Ï¥ÎCASE»y¥y±±¨î¬yµ{ 415 16.13.3 ¨Ï¥ÎLOOP»y¥y±±¨î¬yµ{ 417 16.13.4 ¨Ï¥ÎLEAVE»y¥y±±¨î¬yµ{ 418 16.13.5 ¨Ï¥ÎITERATE»y¥y±±¨î¬yµ{ 418 16.13.6 ¨Ï¥ÎREPEAT»y¥y±±¨î¬yµ{ 419 16.13.7 ¨Ï¥ÎWHILE»y¥y±±¨î¬yµ{ 420 16.14 ¥»³¹Á`µ² 421 ²Ä17³¹ MySQLIJµo¾¹ 422 17.1 ³Ð«ØIJµo¾¹ 422 17.1.1 »yªk®æ¦¡ 422 17.1.2 ³Ð«ØIJµo¾¹¥Ü¨Ò 423 17.2 ¬d¬ÝIJµo¾¹ 425 17.2.1 ¨Ï¥ÎSHOW TRIGGERS»y¥y¬d¬ÝIJµo¾¹ªº«H®§ 425 17.2.2 ¨Ï¥ÎSHOW CREATE TRIGGER»y¥y¬d¬ÝIJµo¾¹ªº«H®§ 426 17.2.3 ³q¹L¬d¬Ýtriggers¼Æ¾Úªí¤¤ªº¼Æ¾Ú¬d¬ÝIJµo¾¹ªº«H®§ 427 17.3 §R°£Ä²µo¾¹ 429 17.3.1 »yªk®æ¦¡ 429 17.3.2 §R°£Ä²µo¾¹¥Ü¨Ò 429 17.4 ¥»³¹¤pµ² 429 ²Ä18³¹ MySQL¤À°Ï 430 18.1 ¤À°Ï¤¶²Ð 430 18.1.1 ¤£¦Pª©¥»MySQLªº¤À°Ï 430 18.1.2 ¤À°ÏªºÀu¶Õ 432 18.1.3 ¤À°ÏÃþ«¬ 433 18.2 RANGE¤À°Ï 434 18.2.1 ³Ð«Ø¤À°Ïªí 434 18.2.2 ²K¥[¤À°Ï 437 18.2.3 §R°£¤À°Ï 438 18.2.4 «©w¸q¤À°Ï 440 18.3 LIST¤À°Ï 442 18.3.1 ³Ð«Ø¤À°Ïªí 442 18.3.2 ²K¥[¤À°Ï 443 18.3.3 §R°£¤À°Ï 444 18.3.4 «©w¸q¤À°Ï 444 18.4 COLUMNS¤À°Ï 445 18.4.1 RANGE COLUMNS¤À°Ï 446 18.4.2 LIST COLUMNS¤À°Ï 447 18.5 HASH¤À°Ï 448 18.5.1 ³Ð«Ø¤À°Ïªí 448 18.5.2 ²K¥[¤À°Ï 449 18.5.3 ¦X¦}¤À°Ï 450 18.6 KEY¤À°Ï 451 18.7 ¤l¤À°Ï 452 18.8 ¤À°Ï¤¤ªºNULLȳB²z 452 18.8.1 RANGE¤À°Ï¤¤ªºNULLÈ 452 18.8.2 LIST¤À°Ï¤¤ªºNULLÈ 453 18.8.3 HASH¤À°Ï»PKEY¤À°Ï¤¤ªºNULLÈ 454 18.9 ¥»³¹Á`µ² 455 ²Ä19³¹ MySQL¤½¥Îªíªí¹F¦¡©M¥Í¦¨¦C 456 19.1 ¤½¥Îªíªí¹F¦¡ 456 19.1.1 «D»¼ÂkCTE 456 19.1.2 »¼ÂkCTE 457 19.1.3 »¼ÂkCTEªº¨î 459 19.2 ¥Í¦¨¦C 461 19.2.1 ³Ð«Øªí®É«ü©w¥Í¦¨¦C 462 19.2.2 ¬°¤w¦³ªí²K¥[¥Í¦¨¦C 463 19.2.3 קï¤w¦³ªº¥Í¦¨¦C 464 19.2.4 §R°£¥Í¦¨¦C 464 19.3 ¥»³¹Á`µ² 465 ²Ä4½g MySQLÀu¤Æ ²Ä20³¹ MySQL¬d¸ßÀu¤Æ 468 20.1 SHOW STATUS»y¥y¸ÑªR 468 20.2 EXPLAIN»y¥y¸ÑªR 469 20.3 SHOW PROFILE»y¥y¸ÑªR 477 20.3.1 ¤ÀªRInnoDB¼Æ¾Úªí 478 20.3.2 ¤ÀªRMyISAM¼Æ¾Úªí 480 20.3.3 ¤ÀªRMySQL·½½X 481 20.4 pt-query-digest¤ÀªR¬d¸ß 482 20.5 Àu¤Æ¤l¬d¸ß 483 20.6 ¥»³¹Á`µ² 483 ²Ä21³¹ MySQL¯Á¤ÞÀu¤Æ 484 21.1 ¯Á¤ÞªºÃþ«¬ 484 21.2 ¨Ï¥Î¯Á¤Þªº³õ´º 485 21.2.1 ¥þȤǰt 485 21.2.2 ¬d¸ßS³ò 486 21.2.3 ¤Ç°t³Ì¥ª«eºó 486 21.2.4 ¬d¸ß¯Á¤Þ¦C 487 21.2.5 ¤Ç°t¦r¬q«eºó 487 21.2.6 ºë½T»PS³ò¤Ç°t¯Á¤Þ 488 21.2.7 ¤Ç°tNULLÈ 488 21.2.8 ³s±µ¬d¸ß¤Ç°t¯Á¤Þ 489 21.2.9 LIKE¤Ç°t¯Á¤Þ 490 21.3 µLªk¨Ï¥Î¯Á¤Þªº³õ´º 490 21.3.1 ¥H³q°t²Å¶}©lªºLIKE»y¥y 490 21.3.2 ¼Æ¾ÚÃþ«¬Âà´« 491 21.3.3 Áp¦X¯Á¤Þ¥¼¤Ç°t³Ì¥ª¦C 491 21.3.4 OR»y¥y 492 21.3.5 pºâ¯Á¤Þ¦C 492 21.3.6 S³ò±ø¥ó¥k°¼ªº¦CµLªk¨Ï¥Î¯Á¤Þ 493 21.3.7 ¨Ï¥Î<>©Î!=¾Þ§@²Å¤Ç°t¬d¸ß±ø¥ó 493 21.3.8 ¤Ç°tNOT NULLÈ 493 21.3.9 ¯Á¤Þ¯Ó®É 494 21.4 ¨Ï¥Î¯Á¤Þ´£¥Ü 494 21.4.1 ¨Ï¥Î¯Á¤Þ 494 21.4.2 ©¿²¤¯Á¤Þ 495 21.4.3 ±j¨î¨Ï¥Î¯Á¤Þ 495 21.5 ¨Ï¥Î¥Í¦¨¦C¬°JSON«Ø¥ß¯Á¤Þ 496 21.6 ¥»³¹Á`µ² 497 ²Ä22³¹ SQL»y¥yÀu¤Æ 498 22.1 ´O®M¬d¸ßªºÀu¤Æ 498 22.2 OR±ø¥ó»y¥yªºÀu¤Æ 500 22.3 ORDER BY»y¥yªºÀu¤Æ 501 22.4 GROUP BY»y¥yªºÀu¤Æ 502 22.5 ¤À¶¬d¸ßªºÀu¤Æ 503 22.5.1 ¦^ªí¬d¸ßÀu¤Æ¤À¶ 503 22.5.2 °O¿ý¼Æ¾Ú¼ÐÃÑÀu¤Æ¤À¶ 504 22.6 ´¡¤J¼Æ¾ÚªºÀu¤Æ 505 22.6.1 MyISAM¼Æ¾Úªí´¡¤J¼Æ¾ÚªºÀu¤Æ 505 22.6.2 InnoDB¼Æ¾Úªí´¡¤J¼Æ¾ÚªºÀu¤Æ 506 22.7 §R°£¼Æ¾ÚªºÀu¤Æ 506 22.8 ¥»³¹Á`µ² 507 ²Ä23³¹ ¼Æ¾Ú®wÀu¤Æ 508 23.1 Àu¤Æ¼Æ¾ÚÃþ«¬ 508 23.1.1 ¨Ï¥Î¼Æ¾ÚÃþ«¬ªº°ò¥»ì«h 508 23.1.2 Àu¤Æªí¤¤ªº¼Æ¾ÚÃþ«¬ 509 23.2 §R°£«´_¯Á¤Þ©M¤¾§E¯Á¤Þ 511 23.2.1 ³Ð«Ø´ú¸Õ¯Á¤Þ 511 23.2.2 ¨Ï¥Îpt-duplicate-key-checker§R°£«´_¯Á¤Þ©M¤¾§E¯Á¤Þ 511 23.2.3 ¨Ï¥Îmysqlindexcheck§R°£«´_¯Á¤Þ©M¤¾§E¯Á¤Þ 513 23.3 ¤ÏS¦¡¤Æ³]p 514 23.4 ¼W¥[¤¤¶¡ªí 515 23.5 ¤ÀªR¼Æ¾Úªí 517 23.6 Àˬd¼Æ¾Úªí 518 23.7 Àu¤Æ¼Æ¾Úªí 518 23.8 ©î¤À¼Æ¾Úªí 519 23.8.1 ««ª½©î¤À¼Æ¾Úªí 519 23.8.2 ¤ô¥©î¤À¼Æ¾Úªí 520 23.9 ¥»³¹Á`µ² 520 ²Ä24³¹ MySQLªA°È¾¹Àu¤Æ 521 24.1 MySQLªA°È¾¹µw¥óªºÀu¤Æ 521 24.1.1 Àu¤Æµw¥ó°t¸m 521 24.1.2 ¨t²Î¤º®ÖÀu¤Æ 522 24.2 MySQL°t¸m¶µªºÀu¤Æ 523 24.3 ¥»³¹Á`µ² 524 ²Ä25³¹ À³¥Îµ{§ÇÀu¤Æ 525 25.1 ´_¥Î¼Æ¾Ú®w³s±µ 525 25.2 ´î¤Ö¼Æ¾Ú³X°Ý 526 25.3 ¶}±Ò¬d¸ß½w¦s 527 25.4 ¨Ï¥Î¥~³¡½w¦s 528 25.5 ¨Ï¥Î¤À¥¬¦¡MySQL¬[ºc 529 25.6 ¥»³¹Á`µ² 529 ²Ä26³¹ MySQLªº¨ä¥LÀu¤Æ¿ï¶µ 530 26.1 ¨Ï¥Îperformance_schema¼Æ¾Ú®w¤ÀªRMySQL 530 26.1.1 ¬d¬ÝMySQL¬O§_¤ä«ùperformance_schema 530 26.1.2 ¶}±Ò©ÎÃö³¬performance_schema 532 26.1.3 performance_schemaªºÂ²³æ°t¸m»P¨Ï¥Î 532 26.2 ¨Ï¥Îsys¼Æ¾Ú®w¤ÀªRMySQL 535 26.2.1 sys¼Æ¾Ú®w·§z 535 26.2.2 sys¼Æ¾Ú®wªº±`¥Î¬d¸ß 535 26.3 MySQL 8.x¤¤ªº¸ê·½²Õ 538 26.3.1 ¶}±Ò CAP_SYS_NICE 538 26.3.2 ³Ð«Ø¸ê·½²Õ 539 26.3.3 ¬d¬Ý¸ê·½²Õ 540 26.3.4 ¸j©w¸ê·½²Õ 540 26.3.5 קï¸ê·½²Õ 542 26.3.6 ¶}±Ò»P¸T¥Î¸ê·½²Õ 542 26.3.7 §R°£¸ê·½²Õ 543 26.4 ¥»³¹Á`µ² 544 ²Ä5½g MySQL¹Bºû ²Ä27³¹ MySQL©R¥O¦æ¤u¨ã 546 27.1 ¬d¬ÝMySQL©R¥O 546 27.2 mysql©R¥O 547 27.2.1 µn¿ýMySQL²×ºÝ 547 27.2.2 ³]¸m«È¤áºÝ³s±µ½s½X 549 27.2.3 ª½±µ°õ¦æSQL»y¥y 550 27.2.4 ®æ¦¡¤Æ¿é¥Xµ²ªG 550 27.2.5 SQL³ø¿ù³B²z 551 27.3 mysqladmin©R¥O 552 27.3.1 mysqladmin©R¥O°Ñ¼Æ 553 27.3.2 mysqladmin©R¥O²³æ¥Ü¨Ò 553 27.4 myisampack©R¥O 554 27.5 mysqlbinlog©R¥O 555 27.6 mysqlcheck©R¥O 558 27.7 mysqlshow©R¥O 559 27.8 mysqldump©R¥O 561 27.9 mysqlimport©R¥O 563 27.10 ¥»³¹Á`µ² 564 ²Ä28³¹ MySQL¤é§Ó 565 28.1 ¬d¸ß¤é§Ó 565 28.1.1 ¶}±Ò¬d¸ß¤é§Ó 565 28.1.2 ¬d¬Ý¬d¸ß¤é§Ó 566 28.1.3 §R°£¬d¸ß¤é§Ó 567 28.1.4 Ãö³¬¬d¸ß¤é§Ó 568 28.2 ºC¬d¸ß¤é§Ó 568 28.2.1 ¶}±ÒºC¬d¸ß¤é§Ó 568 28.2.2 ¬d¬ÝºC¬d¸ß¤é§Ó 569 28.2.3 §R°£ºC¬d¸ß¤é§Ó 570 28.2.4 Ãö³¬ºC¬d¸ß¤é§Ó 571 28.3 ¿ù»~¤é§Ó 571 28.3.1 ¶}±Ò¿ù»~¤é§Ó 571 28.3.2 ¬d¬Ý¿ù»~¤é§Ó 572 28.3.3 §R°£¿ù»~¤é§Ó 572 28.3.4 Ãö³¬¿ù»~¤é§Ó 573 28.4 ¤G¶i¨î¤é§Ó 573 28.4.1 ¶}±Ò¤G¶i¨î¤é§Ó 573 28.4.2 ¬d¬Ý¤G¶i¨î¤é§Ó 574 28.4.3 §R°£¤G¶i¨î¤é§Ó 575 28.4.4 ¼È®É°±¤î»P¶}±Ò¤G¶i¨î¤é§Ó 577 28.4.5 Ãö³¬¤G¶i¨î¤é§Ó 577 28.5 ¥»³¹Á`µ² 577 ²Ä29³¹ ¼Æ¾Ú³Æ¥÷»P«ì´_ 578 29.1 °ò¤_mysqldump³Æ¥÷¦}«ì´_¼Æ¾Ú 578 29.1.1 ³Æ¥÷¼Æ¾Ú 578 29.1.2 «ì´_¼Æ¾Ú 581 29.2 °ò¤_mysqlpump³Æ¥÷¦}«ì´_¼Æ¾Ú 582 29.3 °ò¤_mydumper³Æ¥÷¦}«ì´_¼Æ¾Ú 583 29.3.1 ¦w¸Ëmydumper 583 29.3.2 ³Æ¥÷¼Æ¾Ú 584 29.3.3 «ì´_¼Æ¾Ú 588 29.4 °ò¤_mysqlhotcopy³Æ¥÷¦}«ì´_¼Æ¾Ú 589 29.4.1 ¦w¸Ëmysqlhotcopy 589 29.4.2 ³Æ¥÷¼Æ¾Ú 590 29.4.3 «ì´_¼Æ¾Ú 590 29.5 °ò¤_xtrabackup³Æ¥÷¦}«ì´_¼Æ¾Ú 590 29.5.1 ¦w¸Ëxtrabackup 590 29.5.2 ³Æ¥÷¼Æ¾Ú 591 29.5.3 «ì´_·Ç³Æ 593 29.5.4 «ì´_¼Æ¾Ú 594 29.6 ¼Æ¾Ú³Æ¥÷»P«ì´_®×¨Ò 596 29.6.1 §¹¥þ«ì´_¼Æ¾Ú®×¨Ò 596 29.6.2 °ò¤_¦ì¸mÂI«ì´_¼Æ¾Ú®×¨Ò 598 29.6.3 °ò¤_®É¶¡ÂI«ì´_¼Æ¾Ú®×¨Ò 598 29.7 MySQL¨aÃø«ì´_ 598 29.7.1 °ÝÃD«²{ 599 29.7.2 °ÝÃD¤ÀªR 599 29.7.3 °ÝÃD¸Ñ¨M 600 29.8 ¹ê²{¼Æ¾Ú®wªº¦Û°Ê³Æ¥÷ 602 29.9 ¾É¥X¼Æ¾Ú 603 29.9.1 ¨Ï¥ÎSELECT INTO OUTFILE»y¥y¾É¥X¼Æ¾Ú 603 29.9.2 ¨Ï¥Îmysqldump©R¥O¾É¥X¼Æ¾Ú 605 29.9.3 ¨Ï¥Îmysql©R¥O¾É¥X¼Æ¾Ú 606 29.10 ¾É¤J¼Æ¾Ú 607 29.10.1 ¨Ï¥ÎLOAD DATA INFILE¾É¤J¼Æ¾Ú 608 29.10.2 ¨Ï¥Îmysqlimport¾É¤J¼Æ¾Ú 609 29.11 ¹J¨ìªº°ÝÃD©M¸Ñ¨M¤è®× 610 29.12 ¥»³¹Á`µ² 611 ²Ä30³¹ MySQL½ã¤áºÞ²z 612 30.1 MySQL¤¤ªºÅvªí 612 30.2 ³Ð«Ø´¶³q¥Î¤á 613 30.2.1 ¨Ï¥ÎCREATE USER»y¥y³Ð«Ø¥Î¤á 613 30.2.2 ¨Ï¥ÎGRANT»y¥y³Ð«Ø¥Î¤á 617 30.2.3 ¾Þ§@user¼Æ¾Úªí³Ð«Ø¥Î¤á 619 30.3 ¬°¥Î¤á±ÂÅv 620 30.3.1 Åv¼h¯Å 620 30.3.2 ¨Ï¥ÎGRANT»y¥y¬°¥Î¤á±ÂÅv 621 30.3.3 ³q¹L¾Þ§@Åvªí¬°¥Î¤á±ÂÅv 624 30.4 ¬d¬Ý¥Î¤áÅv 624 30.4.1 ³q¹LSHOW GRANTS FOR»y¥y¬d¬Ý¥Î¤áÅv 624 30.4.2 ³q¹L¬d¸ßmysql.user¼Æ¾Úªí¬d¬Ý¥Î¤áÅv 625 30.4.3 ³q¹L¬d¸ßinformation_schema¼Æ¾Ú®w¬d¬Ý¥Î¤áÅv 625 30.5 קï¥Î¤áÅv 626 30.5.1 ¨Ï¥ÎGRANT»y¥yקï¥Î¤áÅv 626 30.5.2 ³q¹L¾Þ§@¼Æ¾Úªíקï¥Î¤áÅv 627 30.6 ºM¾P¥Î¤áÅv 628 30.6.1 ¨Ï¥ÎREVOKE»y¥yºM¾P¥Î¤áÅv 628 30.6.2 ³q¹L¾Þ§@¼Æ¾ÚªíºM¾P¥Î¤áÅv 629 30.7 קï¥Î¤á±K½X 630 30.7.1 ³q¹Lmysqladminקï¥Î¤á±K½X 630 30.7.2 ¨Ï¥ÎSET PASSWORD»y¥yקï¥Î¤á±K½X 630 30.7.3 ¨Ï¥ÎGRANT»y¥yקï¥Î¤á±K½X 631 30.7.4 ³q¹L¾Þ§@user¼Æ¾Úªíקï¥Î¤á±K½X 632 30.7.5 §Ñ°Oroot±K½Xªº¸Ñ¨M¤è®× 632 30.8 §R°£¥Î¤á 633 30.8.1 ¨Ï¥ÎDROP USER»y¥y§R°£¥Î¤á 633 30.8.2 ¨Ï¥ÎDELETE»y¥y§R°£¥Î¤á 634 30.9 ¨î¥Î¤á¨Ï¥Î¸ê·½ 634 30.9.1 ¨î¥Î¤á¨Ï¥Î¸ê·½¥Ü¨Ò 634 30.9.2 קï¥Î¤áªº¸ê·½¨î 635 30.9.3 ¸Ñ°£¥Î¤áªº¸ê·½¨î 635 30.10 MySQL 8.xª©¥»¤¤ªº½ã¤áºÞ²z 636 30.10.1 ¥Î¤á³Ð«Ø©M±ÂÅv 636 30.10.2 »{ÃÒ´¡¥ó§ó·s 636 30.10.3 ±K½XºÞ²z 638 30.10.4 ¨¤¦âºÞ²z 640 30.11 ¥»³¹Á`µ² 644 ²Ä6½g MySQL¬[ºc ²Ä31³¹ MySQL´_¨î 646 31.1 ·f«ØMySQL¥D±q´_¨îÀô¹Ò 646 31.1.1 ªA°È¾¹³W¹º 646 31.1.2 ·f«ØMySQL¥D±qÀô¹Ò 647 31.1.3 ´ú¸ÕMySQL¥D±q´_¨îÀô¹Ò 650 31.2 ·f«ØMySQL¥D¥D´_¨îÀô¹Ò 652 31.2.1 ªA°È¾¹³W¹º 652 31.2.2 ±NMySQL¥D±qÀô¹Ò¤Á´«¬°¥D¥DÀô¹Ò 652 31.2.3 ª½±µ·f«ØMySQL¥D¥DÀô¹Ò 654 31.2.4 ´ú¸ÕMySQL¥D¥D´_¨îÀô¹Ò 654 31.3 ²K¥[MySQL±q®w 655 31.3.1 ªA°È¾¹³W¹º 655 31.3.2 ¦b¥D±qªA°È¾¹¤W¶i¦æªº¾Þ§@ 656 31.3.3 ´ú¸ÕMySQL¥D±q´_¨îÀô¹Ò 658 31.4 ¤Á´«¥D±q´_¨î¨ìÃ즡´_¨î 659 31.4.1 ªA°È¾¹³W¹º 659 31.4.2 ¤Á´«´_¨î¼Ò¦¡ 660 31.5 ¤Á´«Ã즡´_¨î¨ì¥D±q´_¨î 662 31.6 ·f«ØMySQL¦h·½´_¨îÀô¹Ò 665 31.6.1 ªA°È¾¹³W¹º 665 31.6.2 ·f«ØMySQL¦h·½´_¨îÀô¹Ò 666 31.6.3 ´ú¸ÕMySQL¦h·½´_¨îÀô¹Ò 667 31.7 ²K¥[´_¨î¹LÂo¾¹ 668 31.7.1 ´_¨î«ü©wªº¼Æ¾Ú®w 669 31.7.2 ©¿²¤«ü©wªº¼Æ¾Ú®w 669 31.7.3 ´_¨î«ü©wªº¼Æ¾Úªí 670 31.7.4 ©¿²¤«ü©wªº¼Æ¾Úªí 670 31.8 ³]¸m©µ¿ð´_¨î 671 31.9 °ò¤_GTID·f«ØMySQL¥D±q´_¨îÀô¹Ò 671 31.10 °ò¤_¥b¦P¨B¼Ò¦¡·f«ØMySQL¥D±q´_¨îÀô¹Ò 673 31.10.1 ¥b¦P¨B°Ñ¼Æ»¡©ú 673 31.10.2 °t¸m¥b¦P¨B´_¨î 674 31.10.3 ´ú¸Õ¥b¦P¨B´_¨î 676 31.11 ¥»³¹Á`µ² 677 ²Ä32³¹ MySQLŪ¼g¤ÀÂ÷ 678 32.1 °ò¤_MySQL Proxy¹ê²{Ū¼g¤ÀÂ÷ 678 32.1.1 ªA°È¾¹³W¹º 678 32.1.2 ¦w¸ËLuaÀô¹Ò 679 32.1.3 ¦w¸ËMySQL Proxy 679 32.1.4 °t¸mMySQL ProxyŪ¼g¤ÀÂ÷ 680 32.1.5 ±Ò°ÊMySQL Proxy 683 32.1.6 ´ú¸ÕMySQL ProxyªºÅª¼g¤ÀÂ÷ 683 32.2 °ò¤_Atlas¹ê²{Ū¼g¤ÀÂ÷ 685 32.2.1 ªA°È¾¹³W¹º 685 32.2.2 ¦w¸ËAtlas 685 32.2.3 °t¸mAtlasŪ¼g¤ÀÂ÷ 686 32.2.4 ±Ò°ÊAtlas 687 32.2.5 ´ú¸ÕAtlasŪ¼g¤ÀÂ÷ 689 32.3 °ò¤_ProxySQL¹ê²{Ū¼g¤ÀÂ÷ 689 32.3.1 ªA°È¾¹³W¹º 689 32.3.2 ¦w¸ËProxySQL 690 32.3.3 °t¸mProxySQLŪ¼g¤ÀÂ÷ 690 32.3.4 ´ú¸ÕProxySQLŪ¼g¤ÀÂ÷ 695 32.4 °ò¤_Amoeba¹ê²{Ū¼g¤ÀÂ÷ 695 32.4.1 ªA°È¾¹³W¹º 695 32.4.2 ¦w¸ËJDK 695 32.4.3 ¦w¸ËAmoeba 696 32.4.4 °t¸mAmoebaŪ¼g¤ÀÂ÷ 697 32.4.5 ±Ò°ÊAmoeba 699 32.4.6 ´ú¸ÕAmoebaŪ¼g¤ÀÂ÷ 700 32.5 °ò¤_Mycat¹ê²{Ū¼g¤ÀÂ÷ 700 32.5.1 ªA°È¾¹³W¹º 701 32.5.2 ¦w¸ËJDK 701 32.5.3 ¦w¸ËMycat 701 32.5.4 °t¸mMycatŪ¼g¤ÀÂ÷ 702 32.5.5 ±Ò°ÊMycat 703 32.5.6 ´ú¸ÕMycatŪ¼g¤ÀÂ÷ 704 32.6 ¥»³¹Á`µ² 704 ²Ä33³¹ MySQL HA°ª¥i¥Î¬[ºc 705 33.1 °ò¤_Keepalived·f«ØMySQL°ª¥i¥ÎÀô¹Ò 705 33.1.1 ªA°È¾¹³W¹º 705 33.1.2 ¦w¸ËKeepalived 706 33.1.3 °t¸mMySQL°ª¥i¥Î 707 33.1.4 ´ú¸ÕMySQL°ª¥i¥Î 710 33.1.5 ¦Û°Ê«±ÒMySQL 711 33.2 °ò¤_HAProxy·f«ØMycat°ª¥i¥ÎÀô¹Ò 713 33.2.1 ªA°È¾¹³W¹º 713 33.2.2 ¦w¸ËMycatª¬ºAÀˬdªA°È 713 33.2.3 ¦w¸ËHAProxyªA°È 715 33.2.4 °t¸mMycatt¸ü§¡¿Å 716 33.2.5 ´ú¸ÕMycat°ª¥i¥ÎÀô¹Ò 719 33.3 °ò¤_Keepalived·f«ØHAProxy°ª¥i¥ÎÀô¹Ò 721 33.3.1 ªA°È¾¹³W¹º 721 33.3.2 ¦w¸Ë¦}°t¸mHAProxy©MKeepalived 721 33.3.3 °t¸mHAProxy°ª¥i¥Î©Ê 722 33.3.4 ´ú¸ÕHAProxy°ª¥i¥Î©Ê 725 33.4 ¥»³¹Á`µ² 726 °Ñ¦Ò¤åÄm 727 |
§Ç¡G |
|