Please, help me optimize this MySQL query which takes more than 4s... :( : SELECT 
  COUNT(*) AS dctrn_count 
FROM 
  (
    SELECT 
      DISTINCT id_4 
    FROM 
      (
        SELECT 
          1 / LOCATE(
            ?, 
            CONCAT(
              CONCAT(
                CONCAT(w0_.firstname, ' '), 
                CONCAT(w0_.lastname, ' ')
              ), 
              w1_.fullname
            )
          ) AS sclr_0, 
          1 / LOCATE(
            ?, 
            CONCAT(
              CONCAT(
                CONCAT(w0_.firstname, ' '), 
                CONCAT(w0_.lastname, ' ')
              ), 
              w1_.shortname
            )
          ) AS sclr_1, 
          1 / LOCATE(
            ?, 
            CONCAT(
              CONCAT(
                CONCAT(w0_.nickname, ' '), 
                CONCAT(w0_.lastname, ' ')
              ), 
              w1_.fullname
            )
          ) AS sclr_2, 
          1 / LOCATE(
            ?, 
            CONCAT(
              CONCAT(
                CONCAT(w0_.nickname, ' '), 
                CONCAT(w0_.lastname, ' ')
              ), 
              w1_.shortname
            )
          ) AS sclr_3, 
          w0_.id AS id_4, 
          w0_.slug AS slug_5, 
          w0_.firstname AS firstname_6, 
          w0_.lastname AS lastname_7, 
          w0_.nickname AS nickname_8, 
          w0_.gender AS gender_9, 
          w0_.email AS email_10, 
          w0_.email_checked AS email_checked_11, 
          w0_.title_en AS title_en_12, 
          w0_.short_title AS short_title_13, 
          w0_.start_date AS start_date_14, 
          w0_.end_date AS end_date_15, 
          w0_.is_board_member AS is_board_member_16, 
          w0_.board_date AS board_date_17, 
          w0_.created AS created_18, 
          w0_.updated AS updated_19, 
          w0_.published AS published_20, 
          w1_.id AS id_21, 
          w1_.fullname AS fullname_22, 
          w1_.shortname AS shortname_23, 
          w1_.slug AS slug_24, 
          w1_.workforce AS workforce_25, 
          w1_.fiscal_year_end AS fiscal_year_end_26, 
          w1_.about_en AS about_en_27, 
          w1_.about_fr AS about_fr_28, 
          w1_.stock_symbol AS stock_symbol_29, 
          w1_.stock_exchange AS stock_exchange_30, 
          w1_.is_to_watch AS is_to_watch_31, 
          w1_.count_executives AS count_executives_32, 
          w1_.count_following AS count_following_33, 
          w1_.review_class AS review_class_34, 
          w1_.created AS created_35, 
          w1_.updated AS updated_36, 
          w2_.id AS id_37, 
          w3_.id AS id_38, 
          w3_.country_name AS country_name_39, 
          w3_.country_name_fr AS country_name_fr_40, 
          w3_.country_name_en AS country_name_en_41, 
          w3_.slug AS slug_42, 
          w4_.id AS id_43, 
          w4_.city_name AS city_name_44, 
          w4_.slug AS slug_45, 
          w4_.is_top AS is_top_46, 
          w5_.id AS id_47, 
          w5_.firstname AS firstname_48, 
          w5_.lastname AS lastname_49, 
          w5_.nickname AS nickname_50, 
          w5_.birth_date AS birth_date_51, 
          w5_.twitter_account AS twitter_account_52, 
          w5_.twitter_url AS twitter_url_53, 
          w5_.biography_fr AS biography_fr_54, 
          w5_.biography_en AS biography_en_55, 
          w5_.created AS created_56, 
          w5_.updated AS updated_57, 
          w6_.id AS id_58, 
          w6_.web_text AS web_text_59, 
          w6_.created AS created_60 
        FROM 
          wmn_executive w0_ 
          INNER JOIN wmn_company w1_ ON w0_.company_id = w1_.id 
          INNER JOIN wmn_industry w7_ ON w1_.industry_id = w7_.id 
          INNER JOIN wmn_location w2_ ON w1_.location_id = w2_.id 
          INNER JOIN wmn_country w3_ ON w2_.country_id = w3_.id 
          INNER JOIN wmn_city w4_ ON w2_.city_id = w4_.id 
          LEFT JOIN wmn_executive_link w5_ ON w0_.link_id = w5_.id 
          LEFT JOIN wmn_web_executive w6_ ON w0_.id = w6_.executive_id 
        WHERE 
          w0_.original_id IS NULL 
          AND w0_.user_id IS NOT NULL 
          AND (
            w0_.firstname LIKE ? 
            OR w0_.lastname LIKE ? 
            OR w0_.nickname LIKE ? 
            OR w1_.fullname LIKE ? 
            OR w1_.shortname LIKE ? 
            OR w0_.title_en LIKE ? 
            OR w0_.short_title LIKE ? 
            OR w7_.industry_name_en LIKE ? 
            OR w7_.industry_name_fr LIKE ? 
            OR w3_.country_name_en LIKE ? 
            OR w3_.country_name_fr LIKE ? 
            OR w4_.city_name LIKE ?
          ) 
        ORDER BY 
          sclr_0 DESC, 
          sclr_1 DESC, 
          sclr_2 DESC, 
          sclr_3 DESC
      ) dctrn_result
  ) dctrn_table