For any dynamic site data is the most valuable thing. Without data dynamic site is valueless. Day by day data are added into your server. And after a certain period of time (depending on the amount of data you insert) there are huge amount of data into your server. Moreover, dynamic sites drive in such a manner that, data are fetched(read) from database and display in site.
Now the question is when there will be a large amount of data in your web site, isn't it take much time to read data from the database and makes your site slow to slower automatically. The answer is yes. No doubt : your site will be slower as data inserted into your system. Now the question arise : OPTIMIZATION.
Optimization have a vital role in performance issue. Now this is one possible way to optimize your database (mysql). Use this line of code:
optimize table TableName;
analyze table TableName;
ALTER TABLE ` TableName` ADD INDEX ( `fieldID` ) ;
Or
ALTER TABLE ` TableName` ADD INDEX ( ` fieldID1` , ` fieldID2` ) ;
I think it will be helpful for you. Let me know is it helpful enough?
No comments:
Post a Comment