There are SQL statements: {code...}, but after the explanation, for example: Obviously the index does not take effect, how to create a correct index for table Association.
SQL statements:
SELECTp. *, f. * FROMuchome_posts pLEFT JOIN uchome_postsfield f ON p. pid = f. pidWHEREp. tid = '2016' AND p. HASH = 'authorization' ORDER BYp. pid ASCLIMIT 1557
However, the explanation is as follows:
Obviously, the index does not take effect. How to Create a correct Index associated with the table.
Reply content:
SQL statements:
SELECTp. *, f. * FROMuchome_posts pLEFT JOIN uchome_postsfield f ON p. pid = f. pidWHEREp. tid = '2016' AND p. HASH = 'authorization' ORDER BYp. pid ASCLIMIT 1557
However, the explanation is as follows:
Obviously, the index does not take effect. How to Create a correct Index associated with the table.
Which index do you think is not effective? If you are referring to using filesort, check if the p. HASH field has an index, and the using file sort is not necessarily directly related to the index. Refer to this article
Http://www.taobaodba.com/html/235_mys...