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

¹ØÓÚmysqlµÄ¾Û¼¯Ë÷Òý

·­Ò룺
InnoDB±í»á°üº¬Ò»¸ö¾Û¼¯Ë÷Òý£¨Êý¾Ý±íµÄÎïÀí´æ´¢Ë³ÐòºÍ±íµÄÂß¼­´æ´¢Ë³ÐòÒ»Ö£©
Ò»°ãÊǰ´ÕÕÏÂÃæµÄ¹æÔòÀ´É趨¾Û¼¯Ë÷ÒýµÄ£º
1£¬¼ÙÈç±í°üº¬PRIMARY KEY£¬InnoDBʹÓÃËü×÷Ϊ¾Û¼¯Ë÷Òý
2£¬¼ÙÈç±íûÓж¨ÒåPRIMARY KEY£¬InnoDB½«µÚÒ»¸öÖ»°üº¬NOT NULLÊôÐÔÁеÄUNIQUE index×÷ΪÖ÷¼ü²¢ÇÒ½«ËüÉèÖÃΪ¾Û¼¯Ë÷Òý
3£¬Ç°Á½Õß¶¼²»Âú×ãµÄʱºò£¬mysql¾ÍÔö¼ÓÒ»¸öÒþ²ØµÄautocreament
Every InnoDB
table has a special index called
the clustered index
where the data for
the rows is stored:

If you define a PRIMARY KEY
on your
table, InnoDB
uses it as the clustered
index.

If you do not define a PRIMARY KEY
for
your table, MySQL picks the first UNIQUE
index that has only NOT NULL
columns as
the primary key and InnoDB
uses it as the
clustered index.

If the table has no PRIMARY KEY
or
suitable UNIQUE
index,
InnoDB
internally generates a hidden
clustered index on a synthetic column containing row ID
values. The rows are ordered by the ID that
InnoDB
assigns to the rows in such a
table. The row ID is a 6-byte field that increases
monotonically as new rows are inserted. Thus, the rows
ordered by the row ID are physically in insertion order.

Accessing a row through the clustered index is fast because the
row data is on the same page where the index search leads. If a
table is large, the clustered index architecture often saves a
disk I/O operation when compared to storage organizations that
store row data using a different page from the index record.
(For example, MyISAM
uses one file for data
rows and another for index records.)

In InnoDB
, the records in nonclustered
indexes (also called secondary indexes) contain the primary ke


Ïà¹ØÎĵµ£º

asp.netÁ¬½ÓmysqlµÄÎÊÌâ

Ò»£ºasp.netÔõôÁ¬½ÓmysqlÊý¾Ý¿â
   ÏÂÔØmysql connectionµÄ¶«Î÷
   http://dev.mysql.com/downloads/connector/net/6.2.html
   ÓÐ3¸ödownloadÑ¡µÚÒ»¸öÏÂÔØ
   Windows (x86, 32-bit), ZIP Archive 
   mysql-connector-net-6.2.2-noinstall.zip ......

MySQL¶¯Ô±14000ÈËÇ©Ãû·´¶Ô¼×¹ÇÎÄSun½»Ò×

¾Ý¹úÍâýÌ屨µÀ£¬MySQLÊý¾Ý¿âµÄ¿ª·¢ÕßMichael WideniusÒÔ¼°²¿·ÖÏà¹ØÈËÊ¿½üÈÕÏòÅ·ÖÞ¡¢ÖйúÓë¶íÂÞ˹µÄ¼à¹Ü»ú¹¹Ìá½»Á˶Լ׹ÇÎÄ-Sun½»Ò׵ķ´¶ÔÒâ¼û£¬ÓдóÔ¼14000ÈËÔÚ¸ÃÒâ¼ûÉÏÇ©×Ö±íʾËûÃǶԴËÊÕ¹ºµÄ·´¶Ô¡£Å·ÃËίԱ»á´ËÇ°Ôø·´¶Ô¼×¹ÇÎÄÊÕ¹ºSun£¬µ«Õâһ¢¶ÏÉó²é»ú¹¹ÔÚ12ÔÂÓֳƣ¬¶Ô´Ë½»Ò×´ï³ÉÒ»¸öÂúÒâµÄ½á¹û±íʾÀÖ¹Û¡£Å·ÃËίԱ»á½«Ô ......

UbuntuϳöÏÖMysql error(2002)µÄ½â¾ö·½·¨

      ¹ýÁËÒ»Õó×Óºó£¬ÎªÁËд·Ö²¼Ê½×÷Òµ£¬ÖØÐÂʹÓÃMysqlʱ£¬·¢ÏÖËäÈ»Æô¶¯³É¹¦ÁË£¬µ«ÊÇÁ¬½ÓµÄʱºòÈ¥³öÏÖÈçÏ´íÎó
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)
¸ù¾ÝÌáʾÊÇ/var/run/mysqld/mysqld.sockÎļþ²»´æÔÚ¡£
Ϊʲô»áÕâÑùÄØ£¿
  ......

MysqlÖÐÎÄÂÒÂëÎÊÌâµÄС½á

¸ÅÊö£º
1.ÂÒÂëÎÊÌâ¹é¸ùµ½µ×ÊÇ×Ö·û¼¯µÄÎÊÌâ,ÄǾʹÓ×Ö·û¼¯ÉèÖ÷½Ã濼ÂÇ,²»ÍâºõÏÂÃæ¼¸·½Ã棺
  server(Mysql·þÎñÆ÷),client,database(Êý¾Ý¿â),connection(Á¬½Ó),result
  MySQLµÄ×Ö·û¼¯´¦ÀíÊÇÕâÑùµÄ£º
 £¨1£©·¢ËÍÇëÇó
      ¿Í»§¶Ë(character_set_client£©=¡·Êý¾ ......

JDBC+MySQLÁ¬½Ó³Ø

1.´´½¨Ò»¸öjava projectÏîÄ¿pooling
2.ΪÏîÄ¿Ìí¼ÓMySQLÁ¬½ÓÇý¶¯
3.ΪÏîÄ¿Ìí¼ÓÒ»¸öÅäÖÃÎļþdbpool.proprerties
Code
driverClassName=com.mysql.jdbc.Driver
username=root
password=
url=jdbc:mysql://localhost:3306/work
poolSize=10
 
4.·Ö±ð´´½¨Ò»¸öÁ¬½ÓÀàConnectionPool.javaºÍÒ»¸ö²âÊÔÀàConnectionPoo ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ