表内只有2个字段,
bigint id(primary key)
mediumtext content有22万多数据,任何查询操作都很慢。
我知道问题应该在 content 那个大字段上,对它还做了index,仍然没有效果。
请问有何解决方法?

解决方案 »

  1.   

    用id查询也很慢??你可以在id上做index做查询!!
      

  2.   

    Post your select statement here.OK?
      

  3.   


    select count(id) from tableA;
    select count(content) from tableA;
    select count(*) from tableA;
    select id from tableA;
    select content from tableA;select content from tableA limit 2000;都很慢
      

  4.   

    All of these can not use index at all.
    Try to increase the parameter named read_buffer_size.
      

  5.   

    我用的是innodb 不是 myisam
    我尝试着改了innodb_buffer_pool_size,也没什么效果。
      

  6.   

    innodb的数据引擎的count函数是不使用索引的,它会扫描全表