A technical summary every day to develop a good habit of writing a blog

Source: Internet
Author: User

I just read an interview transcript of C ++'s csdn and said that he would record new knowledge points every day. I feel so good. Now I have already studied it, every day, almost all kinds of new problems are encountered in projects that I usually access. I spend every day focusing on these problems. It is necessary to take half an hour every day to write a knowledge summary, a quick summary of one day's work is also a kind of sorting of your own knowledge. I used to like to remember this book. However, if you don't need it for a long time, you will find it easy to forget it, so I hope I can stick to writing my blog carefully in the future.

Recently, I used vs2008 as a MySQL database query software to implement several simple query functions. Party A raised several requirements because of the large data volume, therefore, it takes a long time to query the Traversal Time. Today I set an index for the table. The index setting method is as follows:

Alter table parts add index idx_model (model );

Parts is the table name, idx_model is the index name, and model is the table field. Setting the index can speed up the query, and the index is equivalent to the database directory, you do not need to traverse the entire table during query. It is much faster to perform a test today.

At the same time, the MySQL database backup is also summarized. If mysqldump is used for backup, Step 1: Enter mysqldump-uroot-proot Database Name> file path (D: \ a.txt) 2. Use the task manager to stop the mysql-NT Service, delete ibdata1 and two log files, and 3. Restart the MySQL service, it will automatically create a new ibdata1 file and two log files, 4, and then use the command line: mysql-uroot-proot database name <file path (D: \ a.txt ), if the data volume is large, it takes a long time to restore the data. Another method is to copy the ibdata1 file and two log files directly, and copy the files back when they are restored. Of course, you also need to move them down when the service is closed.

Today is a good start. I hope to keep doing it every day. Come on!

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.