本帖最后由 gridbagwt 于 2012-02-17 16:44:26 编辑

解决方案 »

  1.   

    建立ID、source、author上的复合索引,去掉单独的索引
      

  2.   

    但是,有可能还是这样的:
    ID 和 source 复合查询,ID 和 author ,source 和 author
    是不是都要建立符合索引?
      

  3.   

    explain 3种SQL语句,看看能否用到ID、source、author上的复合索引
      

  4.   

    一个是索引优化,一个可以考虑做数据缓存吧!如memcache
      

  5.   

    大数据量不要写select * 
      

  6.   

    create index x1 on test(id,source,author);
    create index x1 on test(source,author);
    create index x1 on test(id,author);
      

  7.   

    id,source,author用复合索引,具体看一下执行的计划explain。