Skip to content

Missing indexes in hosts table #59

@GoogleCodeExporter

Description

@GoogleCodeExporter
Hi,

There is slow query in wpkgExpress caused by query like :

SELECT `Host`.`id`, `Host`.`name`, `Host`.`enabled`, `MainProfile`.`id_text` 
FROM `hosts` AS `Host` LEFT JOIN `profiles` AS `MainProfile` ON 
(`Host`.`mainprofile_id` = `MainProfile`.`id`)  WHERE `Host`.`enabled` = 1   
ORDER BY `Host`.`position` asc;

Solution / Mitigation :

add index on enabled field in hosts table :

ALTER TABLE `hosts` ADD INDEX ( `enabled` )

Regards,

Original issue reported on code.google.com by yann.ric...@gmail.com on 1 Mar 2013 at 9:48

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions