MyEclipse Á¬½ÓÔ¶³ÌµÄ MYSQL
mysql Êý¾Ý¿âĬÈϵÄÁ¬½ÓÖ»ÄÜÔÚ±¾»úÁ¬½Ó£¬Ô¶³ÌÁ¬½Ó±ØÐëÊÚȨ¡£
´úÂë: È«Ñ¡
¡¡GRANT ALL PRIVILEGES ON *.* TO 'myuser'@'%'IDENTIFIED
BY 'mypassword' WITH GRANT
OPTION;Èç¹ûÄãÏëÔÊÐíÓû§myuser´ÓipΪ192.168.1.6µÄÖ÷»úÁ¬½Óµ½mysql·þÎñÆ÷£¬²¢Ê¹ÓÃ
mypassword×÷ΪÃÜÂë
´úÂë: GRANT ALL PRIVILEGES ON *.* TO 'root'@'192.168.0.68'IDENTIFIED BY 'admin' WITH GRANT OPTION
¡¡
ÕâÑùÊý¾Ý¿â¾ÍÔÊÐíÔ¶³ÌÁ¬½ÓÁË¡£
µ«ÔÚÓÃMyEclipseµÄdb
browser
Á¬½Óʱ£¬»¹ÊÇÌáʾÎÞ·¨Á¬½Ó¡£ÎҾͻ³ÒÉÊDz»ÊÇÎÒµÄmysqlÇý¶¯°üÓÐÎÊÌâ¡£
¸Õ¿ªÊ¼ÓõÄÇý¶¯°üÊÇmysql-connector-java-3.1.13-bin.jar
£¬»³Òɰ汾̫µÍ£¬½á¹ûÓÖDOWNÁËÒ»¸öеÄmysql-connector-java-5.1.7-bin.jar¡£¼ÌÐøÁ¬½Ó»¹ÊDz»ÐС£
Í·¶¼ÏëÆÆÁË£¬ÍøÉÏ×ÊÁϲéÁËÒ»¶ÑҲû·¢ÏÖÏà¹ØµÄ½â¾ö·½°¸£¬ÓÚÊDZ§×ÅÊÔÊÔ¿´µÄÐÄ̬ȥ²é¿´mysqlµÄÅäÖÃÎļþ
vi
/etc/mysql/my.cnf
½á¹û·¢ÏÖÓÐÕâô¼¸ÐÐ
´úÂë:bind-address = 127.0.0.1
#
# * Fine
Tuning
#
key_buffer = 16M
max_allowed_packet = 16M
thread_stack =
128K
thread_cache_size =
8
´ó¼Ò¿´µ½ÁË°Ébind-address = 127.0.0.1
ÕâÒ»ÐоͰÑÁ¬½ÓµØÖ·¸øÏÞÖÆËÀÁË£¬Ö»Äܱ¾»úÁ¬½Ó¡£ÓÚÊÇÎÒ°ÑÕâÐÐ×¢Ê͵ô\
´úÂë: #bind-address = 127.0.0.1
#
# * Fine
Tuning
#
ÖØÐÂÆô¶¯mysql
´úÂë:sudo /etc/init.d/mysql
restart
ÔÙÓÃMyEclipse Á¬½Ó¡£ÖÕÓڳɹ¦ÁË¡£
Ïà¹ØÎĵµ£º
MysqlËùÖ§³ÖµÄÒýÇæÄ¿Ç°ÓÐÒÔϼ¸ÖÖ£º
MyISAM,InnoDB,MERGE,MEMORY(HEAR),BDB(BerkeleyDB),EXAMPLE,FEDERATED,ARCHIVE,CSV,BLACKHOLE.
ΪʲôҪÓÐÕâô¶àÒýÇ棿Ö÷ÒªÊÇMysqlÊÇÒ»¿î¼«ÎªÇ¿´óµÄÊý¾Ý¿â£¬ËüÊÊÓ¦ºÜ¶à²»Í¬µÄÔËÐл·¾³£¬ÎªÁËÂú×ã¸÷ÖÖ²»Í¬µÄÔËÐл·¾³Óë´æ´¢·½°¸µÄÐèÒª£¬ÕâЩËÑË÷ÒýÇæÒ²¾ÍÓ¦Ô˶øÉú£¨²»¹âÊÇΪÁËÅäºÏMysql ......
À´Ô´£ºhttp://www.blogjava.net/Alpha/archive/2007/07/23/131912.html
//Ö÷¼ü549830479
alter table tabelname add new_field_id int(5) unsigned default 0 not null auto_increment ,add primary key (new_field_id);
//Ôö¼ÓÒ»¸öÐÂÁÐ549830479
alter table t2 add d timestamp;
alter table infos add ......
ÓÉÓÚ×î½üÒ»Ö±ÔÚÁ˽âmysql¡£¸÷ÖÖ±íÀàÐ͵ÄÊý¾Ý´æ´¢ÒÔ¼°Ïà¹ØÏÞÖƾÍÊDZØÐëÁ˽âµÄ·½ÃæÁË¡£
×Ô¼ºµÄ·þÎñÆ÷»·¾³£ºOS Cent OS ext3£¬memory 4G£¬ disk 2T block size 4K¡£
¾µ÷²é£¬linuxÏÂÎļþ×î´óÊÇ´æÔÚÏÞÖƵġ£È¥googleÉÏËÑÁËËÑ£¬´ó¼Ò˵·¨²»Ò»£¬×îÖÕ×Ô¼º»¹ÊÇÕÒµ½±È½Ï¹Ù·½µÄ˵¡£Ïê¼ûhttp://en.wikipedia.org/wiki/Ext3 ËùÒÔ× ......
CREATE [OR REPLACE] [ALGORITHM = {UNDEFINED | MERGE | TEMPTABLE}]
VIEW view_name [(column_list)]
AS select_statement
[WITH [CASCADED | LOCAL] CHECK OPTION]
¸ÃÓï¾äÄÜ´´½¨ÐµÄÊÓͼ£¬Èç¹û¸ø¶¨ÁËOR REPLACE×Ӿ䣬¸ÃÓï¾ä»¹ÄÜÌæ»»ÒÑÓеÄÊÓͼ¡£s ......
Ò».ÏÈ¿´Ò»Ð©×î¼òµ¥µÄÀý×Ó
Àý×Ó
Table A
aid adate
1 a1
2 a2
3 a3
TableB
bid bdate
1 b1
2 b2
4 b4
Á½¸ö±ía,bÏàÁ¬½Ó,Ҫȡ ......