Lighter, faster!
|
|
Monday, 25 August 2008 05:40 |
|
I asked several people, even the PHP mailing-list, about the difference between int(1) and int(11) when creating a MySQL table, The answer is little difference: 1 and 11 (in this case), are used to specify the display width. However, there is a little more. |
|
Read more...
|
|
|
Thursday, 01 May 2008 09:00 |
|
The table used in this case is a user subscription table. Generally this table keeps records of users' subscription details: which topic they subscribed, when they last viewed their topics subscribed, who last replied a topic and when, when a default subscription will be expired (not used currently). Formerly we wanted to use multiple tables. That is, store user $uid's information in table mysubs_$t ($t = $uid%8). After some consideration of the problems may be brought in the future, I decided to use one table. |
|
Read more...
|
|
Tuesday, 25 March 2008 17:00 |
|
This article gives out a relative fastest way to get the number of records from a huge table, which means, the table has millions, or even hundreds of millions, of records. In such huge tables, each possible optimization method is worth considering. Sometimes, evan one single optimized SQL sentence can save you a lot of time, especially in busy websites. Here, the example I will use to take the test is an Innodb, not MyISAM, engined table, which has five indices and 'id' as the primary key, with more than twenty million records. |
|
Read more...
|
|
|
|
|
|
Page 1 of 1 |