Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

mysql»ù±¾ÃüÁî

 Æô¶¯£ºnet start mySql;
  ½øÈ룺mysql -u root -p/mysql -h localhost -u root -p databaseName;
  ÁгöÊý¾Ý¿â£ºshow databases;
  Ñ¡ÔñÊý¾Ý¿â£ºuse databaseName;
  Áгö±í¸ñ£ºshow tables£»
  ÏÔʾ±í¸ñÁеÄÊôÐÔ£ºshow columns from tableName£»
  ½¨Á¢Êý¾Ý¿â£ºsource fileName.txt;
  Æ¥Åä×Ö·û£º¿ÉÒÔÓÃͨÅä·û_´ú±íÈκÎÒ»¸ö×Ö·û£¬£¥´ú±íÈκÎ×Ö·û´®;
  Ôö¼ÓÒ»¸ö×ֶΣºalter table tabelName add column fieldName dateType;
  Ôö¼Ó¶à¸ö×ֶΣºalter table tabelName add column fieldName1 dateType,add columns fieldName2 dateType;
  ¶àÐÐÃüÁîÊäÈë:×¢Òâ²»Äܽ«µ¥´Ê¶Ï¿ª;µ±²åÈë»ò¸ü¸ÄÊý¾Ýʱ£¬²»Äܽ«×ֶεÄ×Ö·û´®Õ¹¿ªµ½¶àÐÐÀ·ñÔòÓ²»Ø³µ½«±»´¢´æµ½Êý¾ÝÖÐ;
  Ôö¼ÓÒ»¸ö¹ÜÀíÔ±ÕÊ»§£ºgrant all on *.* to user@localhost identified by "password";
  ÿÌõÓï¾äÊäÈëÍê±ÏºóÒªÔÚĩβÌî¼Ó·ÖºÅ';'£¬»òÕßÌî¼Ó'\g'Ò²¿ÉÒÔ£»
  ²éѯʱ¼ä£ºselect now();
  ²éѯµ±Ç°Óû§£ºselect user();
  ²éѯÊý¾Ý¿â°æ±¾£ºselect version();
  ²éѯµ±Ç°Ê¹ÓõÄÊý¾Ý¿â£ºselect database();
 
  1¡¢É¾³ýstudent_courseÊý¾Ý¿âÖеÄstudentsÊý¾Ý±í£º
  rm -f student_course/students.*
 
  2¡¢±¸·ÝÊý¾Ý¿â£º(½«Êý¾Ý¿âtest±¸·Ý)
  mysqldump -u root -p test>c:\test.txt
  ±¸·Ý±í¸ñ£º(±¸·ÝtestÊý¾Ý¿âϵÄmytable±í¸ñ)
  mysqldump -u root -p test mytable>c:\test.txt
  ½«±¸·ÝÊý¾Ýµ¼Èëµ½Êý¾Ý¿â£º(µ¼»ØtestÊý¾Ý¿â)
  mysql -u root -p test
 
  3¡¢´´½¨ÁÙʱ±í£º(½¨Á¢ÁÙʱ±ízengchao)
  create temporary table zengchao(name varchar(10));
 
  4¡¢´´½¨±íÊÇÏÈÅжϱíÊÇ·ñ´æÔÚ
  create table if not exists students(……);
 
  5¡¢´ÓÒѾ­ÓеıíÖи´ÖƱíµÄ½á¹¹
  create table table2 select * from table1 where 1<>1;
 
  6¡¢¸´ÖƱí
  create table table2 select * from table1;
 
  7¡¢¶Ô±íÖØÐÂÃüÃû
  alter table table1 rename as table2;
 
  8¡¢ÐÞ¸ÄÁеÄÀàÐÍ
  alter table table1 modify id int unsigned;//ÐÞ¸ÄÁÐidµÄÀàÐÍΪint unsigned
  alte


Ïà¹ØÎĵµ£º

java µ÷ÓÃmysql¿Í»§¶Ëµ¼È룬µ¼³öÊý¾Ý

 ×î½üÓöµ½Ò»¸öÐèÇóÒªÔÚlinuxÏÂÓÃjava µ÷ÓÃmysql¿Í»§¶ËÔ¶³ÌµÇ½mysql·þÎñÆ÷£¬´Ó¿Í»§¶Ë»úÆ÷µ¼Èëmysql½Å±¾£¬´Ómysql·þÎñÆ÷¶Ëµ¼³ö±íÖеÄÊý¾Ý¡£ÒÔÏÂÊÇÓõ½µÄÖ÷Òª·½·¨£º
Java ´úÂë 
/**  
 * µ¼ÈëÊý¾Ý  
  * @param  ½Å±¾µÄµØÖ·ºÍÃû³Æ  
 * @return ÊÇ·ñ³ ......

MySQL Storage Engine

http://www.javaeye.com/topic/211951
Õâ¶Îʱ¼äÔÚ¿´¡¶High Performance MySQL¡·£¬¿´µ½´æ´¢ÒýÇæÕâ¸öµØ·½¸Ðµ½ºÜ¶àϸ½Ú±È½ÏÄ°Éú£¬ËùÒÔ×ܽáС¼ÇһЩ
ΪÁËÊÊÓ¦¸÷ÖÖ²»Í¬µÄÔËÐл·¾³£¬MYSQLÌṩÁ˶àÖÖ²»Í¬µÄ´æ´¢ÒýÇ棨Storage Engine £©,ÔÚÓ¦ÓóÌÐò¿ª·¢Õâ¸ö²ãÃæÉÏ£¬¿ª·¢Õß¿ÉÒÔ¸ù¾Ý²»Í¬µÄÐèÇóÑ¡ÔñÊʺϵÄStorage Engine ·½°¸£¬¸üΪÁ ......

ÈçºÎÌá¸ßMySQLÐÔÄÜ

Ò»¡¢ÎÊÌâµÄÌá³ö
¡¡¡¡ÔÚÓ¦ÓÃϵͳ¿ª·¢³õÆÚ£¬ÓÉÓÚ¿ª·¢Êý¾Ý¿âÊý¾Ý±È½ÏÉÙ£¬¶ÔÓÚ²éѯSQLÓï¾ä£¬¸´ÔÓÊÓͼµÄµÄ±àдµÈÌå»á²»³öSQLÓï¾ä¸÷ÖÖд·¨µÄÐÔÄÜ¡£ÓÅÁÓ£¬µ«ÊÇÈç¹û½«Ó¦ÓÃϵͳÌύʵ¼ÊÓ¦Óúó£¬Ëæ×ÅÊý¾Ý¿âÖÐÊý¾ÝµÄÔö¼Ó£¬ÏµÍ³µÄÏìÓ¦ËٶȾͳÉΪĿǰϵͳÐèÒª½â¾öµÄ×îÖ÷ÒªµÄÎÊÌâÖ®Ò»¡£ÏµÍ³ÓÅ»¯ÖÐÒ»¸öºÜÖØÒªµÄ·½Ãæ¾ÍÊÇSQLÓï¾äµÄÓÅ»¯¡£¶ÔÓ ......

MySql ×Ö·û´®º¯Êý


MySql ×Ö·û´®º¯Êý
[ 2006-04-22 19:24:44 | Author: Ychon ]
Font Size: Large | Medium | Small
¶ÔÓÚÕë¶Ô×Ö·û´®Î»ÖõIJÙ×÷£¬µÚÒ»¸öλÖñ»±ê¼ÇΪ1¡£
ASCII(str)
·µ»Ø×Ö·û´®strµÄ×î×óÃæ×Ö·ûµÄASCII´úÂëÖµ¡£Èç¹ûstrÊÇ¿Õ×Ö·û´®£¬·µ»Ø0¡£Èç¹ûstrÊÇNULL£¬·µ»ØNULL¡£
mysql> select ASCII('2');
-> 50
mysql ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ