EXPLAIN SELECT DISTINCT field_revision_field_sections.entity_type AS entity_type, field_revision_field_sections.entity_id AS entity_id, field_revision_field_sections.revision_id AS revision_id, field_revision_field_sections.bundle AS bundle FROM field_revision_field_sections field_revision_field_sections WHERE (field_revision_field_sections.field_sections_revision_id = '251315') AND (field_revision_field_sections.deleted = '0') AND(( ( EXISTS (SELECT na.nid AS nid FROM node_access na WHERE (( (na.gid = '0') AND (na.realm = 'all') )OR( (na.gid = '1') AND (na.realm = 'taxonomy_access_role') ))AND (na.grant_view >= '1') AND (field_revision_field_sections.entity_id = na.nid) )) AND (field_revision_field_sections.entity_type = 'node') )OR (field_revision_field_sections.entity_type <> 'node') );
+------+--------------+-------------------------------+------+-----------------------------+---------+---------+-------+--------+-----------------------------------------------------+
| id | select_type | table | type | possible_keys | key | key_len | ref | rows | Extra |
+------+--------------+-------------------------------+------+-----------------------------+---------+---------+-------+--------+-----------------------------------------------------+
| 1 | PRIMARY | field_revision_field_sections | ref | PRIMARY,entity_type,deleted | deleted | 1 | const | 54196 | Using index condition; Using where; Using temporary |
| 2 | MATERIALIZED | na | ALL | PRIMARY | NULL | NULL | NULL | 190800 | Using where |
+------+--------------+-------------------------------+------+-----------------------------+---------+---------+-------+--------+-----------------------------------------------------+
+------+--------------------+-------------------------------+----------------+--------------------------------------------------------+----------------------------+---------+-------+------+-----------------------------------------------------+
| id | select_type | table | type | possible_keys | key | key_len | ref | rows | Extra |
+------+--------------------+-------------------------------+----------------+--------------------------------------------------------+----------------------------+---------+-------+------+-----------------------------------------------------+
| 1 | PRIMARY | field_revision_field_sections | ref | PRIMARY,entity_type,deleted,field_sections_revision_id | field_sections_revision_id | 5 | const | 1 | Using index condition; Using where; Using temporary |
| 2 | DEPENDENT SUBQUERY | na | index_subquery | PRIMARY | PRIMARY | 4 | func | 2 | Using where |
+------+--------------------+-------------------------------+----------------+--------------------------------------------------------+----------------------------+---------+-------+------+-----------------------------------------------------+