explain.depesz.com

PostgreSQL's explain analyze made readable

Result: RmIL

Settings
# exclusive inclusive rows x rows loops node
1. 2.097 105.387 ↓ 38.0 38 1

Limit (cost=655.61..657.22 rows=1 width=5,527) (actual time=100.813..105.387 rows=38 loops=1)

2. 2.027 103.290 ↓ 38.0 38 1

Unique (cost=655.61..657.22 rows=1 width=5,527) (actual time=100.792..103.290 rows=38 loops=1)

3. 2.262 101.263 ↓ 38.0 38 1

Sort (cost=655.61..655.61 rows=1 width=5,527) (actual time=100.423..101.263 rows=38 loops=1)

  • Sort Key: (CASE WHEN (messenger_communication."timestamp" IS NOT NULL) THEN 1 ELSE 0 END) DESC, messenger_communication."timestamp" DESC, clients_client.created_at DESC, clients_client.id DESC, clients_client.internal_id, clients_client.onsite_guestcard_id, clients_client.onsite_lease_id, clients_client._people, clients_client.interest_level, clients_client.other_occupants, clients_client.group_id, clients_client.client_referral, clients_client.client_referral_other, clients_client.origin_source, clients_client.lead_source, clients_client.discovery_source, clients_client.current_postal_code, clients_client.lease_term, clients_client.campaign_info, clients_client.loss_reason_type, clients_client.loss_reason_notes, clients_client.loss_reason_building, clients_client.client_location, clients_client.client_occupation, clients_client.client_priorities, clients_client.reason_for_move, clients_client.client_household, clients_client.work_location, clients_client.last_message_id, clients_client.first_touch_id, clients_client.auto_response_enabled, clients_client.notes, clients_client.received_nys_disclosure_form, clients_client.received_government_id, clients_client.received_paystubs, clients_client.received_tax_returns, clients_client.received_bank_statements, clients_client.received_letter_of_employment, clients_client.received_reference_letter, clients_client.received_application, clients_client.paid_app_fee, clients_client.paid_initial_rent, clients_client.paid_deposit, clients_client.sent_application, clients_client._move_in_date, clients_client._client_type, clients_client._price_floor, clients_client._price_ceiling, clients_client._layout, clients_client._bathrooms, clients_client._building_ownership, clients_client._laundry, clients_client._doorman, clients_client._elevator, clients_client._outdoor_space, clients_client._parking, clients_client._postal_code, clients_client._geometry, clients_client._pets, clients_client._pets_count, clients_client._pets_weight, clients_client._pets_no_breed_restriction, clients_client._pets_no_interview_required, clients_client.no_credit_check, clients_client.no_rent_history, clients_client.no_income_requirements, clients_client.felony_record, clients_client.misdemeanor_record, clients_client.bankruptcies, clients_client.broken_leases, clients_client.evictions, clients_client.foreclosures, clients_client.broker_first_name, clients_client.broker_last_name, clients_client.broker_email, clients_client.broker_phone, clients_client.broker_company, clients_client.marketing_email_opt_in, clients_client.email_updates_opt_in, clients_client.sms_opted_in, clients_client.last_event, clients_client.updated_at, clients_client.action_needed, clients_client.action_assigned_to_id, accounts_employeegroup.id, accounts_employeegroup.name, accounts_employeegroup.company_id, accounts_employeegroup."order", accounts_employeegroup.leads_email_id, accounts_employeegroup.central_leasing_team_id, accounts_employeegroup.guided_tour_settings_id, accounts_employeegroup.appointments_sms_alerts, accounts_employeegroup.lead_widget_enabled, accounts_employeegroup.lead_assignment, accounts_employeegroup.lead_widget_settings, accounts_employeegroup.lead_assignment_use_listing_agent, accounts_employeegroup.lead_assignment_last_employee_id, accounts_employeegroup.neighborhoods_config, accounts_employeegroup.layout_config, accounts_employeegroup.layout_options, accounts_employeegroup.min_price_config, accounts_employeegroup.max_price_config, accounts_employeegroup.other_occupants_config, accounts_employeegroup.lease_term_config, accounts_employeegroup.current_postal_code_config, accounts_employeegroup.client_location_config, accounts_employeegroup.move_in_date_config, accounts_employeegroup.pets_config, accounts_employeegroup.amenities_config, accounts_employeegroup.discovery_source_config, accounts_employeegroup.notes_config, accounts_employeegroup.broker_company_config, accounts_employeegroup.broker_toggle_config, accounts_employeegroup.assign_agent_config, accounts_employeegroup.lead_source_config, accounts_employeegroup.reason_for_move_config, accounts_employeegroup.reason_for_move_options, accounts_employeegroup.client_priorities_options, accounts_employeegroup.system_tour_emails_enabled, accounts_employeegroup.agent_assignment_client_notifications_enabled, accounts_employeegroup.auto_response_enabled, accounts_employeegroup.auto_responder_agent_id, accounts_employeegroup.auto_send_use_company_disabled_times, accounts_employeegroup.auto_send_disabled_weekday_start_time, accounts_employeegroup.auto_send_disabled_weekday_end_time, accounts_employeegroup.auto_send_disabled_weekend_start_time, accounts_employeegroup.auto_send_disabled_weekend_end_time, accounts_employeegroup.auto_send_padding_time, accounts_employeegroup.autoreply_template_subject, accounts_employeegroup.autoreply_template_primary, accounts_employeegroup.autoreply_template_pets, accounts_employeegroup.autoreply_template_apartment_search, accounts_employeegroup.autoreply_template_guarantors, accounts_employeegroup.autoreply_template_photo_request, accounts_employeegroup.autoreply_template_floorplan_request, accounts_employeegroup.autoreply_template_concessions, accounts_employeegroup.autoreply_template_utilities, accounts_employeegroup.autoreply_template_apartment_still_available, accounts_employeegroup.autoreply_template_roommate, accounts_employeegroup.timezone, accounts_employeegroup.lead_emails_streeteasy_zumper_renthop_realtor_enabled, accounts_employeegroup.lead_emails_zillow_enabled, accounts_employeegroup.lead_emails_lead_widget_contact_form_enabled, accounts_employeegroup.lead_emails_nestcard_enabled, accounts_employeegroup.lead_emails_phone_calls_enabled, accounts_employeegroup.prevent_tours_outside_of_team_hours, accounts_employeegroup.disallow_manual_appointment_overlap, accounts_employeegroup.default_phone_number_id, clients_discoverysource.id, clients_discoverysource.created_at, clients_discoverysource.updated_at, clients_discoverysource.name, clients_discoverysource.default_company_choice, t10.id, t10.created_at, t10.updated_at, t10.name, t10.default_company_choice, messenger_communication.id, messenger_communication.polymorphic_ctype_id, messenger_communication.created_at, messenger_communication.updated_at, messenger_communication.subject, messenger_communication.text, messenger_communication.client_id, messenger_communication.client_listing_id, messenger_communication.user_sender_id, messenger_communication.user_receiver_id, messenger_communication.seen, messenger_communication.dismissed, messenger_communication.source, messenger_communication.communication_summary_id, django_content_type.id, django_content_type.app_label, django_content_type.model, messenger_action.communication_ptr_id, messenger_action.type, messenger_action.message_type, messenger_action.html_content, messenger_action.reference_message_id, messenger_action.scheduled_time, messenger_action.acted_on, messenger_action.edited_before_action, messenger_action.expiry, messenger_smsornylasemailmessage.communication_ptr_id, messenger_smsornylasemailmessage.type, messenger_smsornylasemailmessage.html_content, messenger_smsornylasemailmessage.to_address, messenger_smsornylasemailmessage.from_address, messenger_smsornylasemailmessage.cc_addresses, messenger_smsornylasemailmessage.bcc_addresses, messenger_smsornylasemailmessage.external_id, messenger_smsornylasemailmessage.reply_to_message_id, messenger_smsornylasemailmessage.thread_id, messenger_smsornylasemailmessage.message_id_header, messenger_smsornylasemailmessage.from_action_id, messenger_smsornylasemailmessage.automation_type, messenger_smsornylasemailmessage.classification_categories, messenger_smsornylasemailmessage.success, messenger_phonecallrecord.communication_ptr_id, messenger_phonecallrecord.phone_call_id, telephony_phonecall.id, telephony_phonecall.created_at, telephony_phonecall.updated_at, telephony_phonecall.parent_sid, telephony_phonecall.building_id, telephony_phonecall.community_id, telephony_phonecall.call_status, telephony_phonecall.client_id, telephony_phonecall.direction, telephony_phonecall.is_syndication, telephony_phonecall.recording_url, telephony_phonecall.duration, telephony_phonecall."timestamp", telephony_phonecall.transcript_url, telephony_phonecall.transcript_text, telephony_phonecall.user_id, telephony_phonecall.is_private, units_building.id, units_building.management_company_id, units_building.owner_id, units_building.building_type, units_building.building_name, units_building.internal_id, units_building.building_number, units_building.street, units_building.normalized_street_address, units_building.floors, units_building.source_identifier, units_building.cross_street_a, units_building.cross_street_b, units_building.postal_code, units_building.city, units_building.state, units_building.lock_location, units_building.location, units_building.primary_neighborhood_id, units_building.region_id, units_building.viewing_instructions, units_building.building_ownership, units_building.tax_block, units_building.tax_lot, units_building.doorman, units_building.air_conditioning, units_building.parking, units_building.total_units, units_building.is_multibuilding_complex, units_building.exclusive, units_building._pets_allowed, units_building.pets_notes, units_building.public_description, units_building.public_url, units_building.contact_name, units_building.contact_email, units_building.contact_phone, units_building.twilio_number, units_building.application_link, units_building.appointment_link, units_building.featured, units_building.private_notes, units_building.listing_public_url_pattern, units_building.internal_viewing_primary_contact, units_building.internal_viewing_phone, units_building.internal_viewing_email, units_building.internal_viewing_notes, units_building.created_at, units_building.updated_at, units_building.source, units_building.lead_assignment_group_id, units_building.lead_assignment_user_id, units_building.canonical_building_id, units_building.auto_sync_from, units_building.has_company_listings, units_building.key_in_office, units_building.key_details, units_building.include_in_streeteasy_building_feed, units_building.renewal_pricing_enabled, units_building.renewal_offer_timing_fair_market, units_building.renewal_offer_timing_rent_stabilized, units_building.price_increase_high, units_building.price_increase_low, units_building.two_year_increase, units_building.community_id, communities_community.id, communities_community.created_at, communities_community.updated_at, communities_community.building_name, communities_community.building_number, communities_community.street, communities_community.postal_code, communities_community.city, communities_community.state, communities_community.cross_street_a, communities_community.cross_street_b, communities_community.normalized_street_address, communities_community.lock_location, communities_community.location, communities_community.primary_neighborhood_id, communities_community.company_id, communities_community.employee_group_id, communities_community.application_url, communities_community.logo, communities_community.description, communities_community.private_notes, communities_community.contact_name, communities_community.contact_phone, communities_community.contact_email, communities_community.website_url, communities_community.air_conditioning, communities_community.doorman, communities_community.elevator, communities_community.fitness_center, communities_community.community_wifi, communities_community.laundry_in_building, communities_community.laundry_on_floor, communities_community.laundry_notes, communities_community.bike_storage, communities_community.package_room, communities_community.valet, communities_community.swimming_pool, communities_community.concierge, communities_community.garden, communities_community.courtyard, communities_community.terrace, communities_community.roof_deck, communities_community.playroom, communities_community.playground, communities_community.picnic_bbq_area, communities_community.clubhouse, communities_community.game_room, communities_community.cinema_room, communities_community.pet_park, communities_community.dry_cleaning, communities_community.lounge, communities_community.handicap_accessible, communities_community.voice_intercom, communities_community.gated, communities_community.other_amenities, communities_community.parking_notes, communities_community.storage, communities_community.storage_fees, communities_community.storage_fee_term, communities_community.storage_notes, communities_community.year_built, communities_community.remodeled, communities_community.commercial_space, communities_community.pets_allowed, communities_community.pets_max_allowed, communities_community.pets_max_weight, communities_community.pets_breed_restriction, communities_community.pets_interview_required, communities_community.pets_deposit, communities_community.pets_deposit_dogs, communities_community.pets_deposit_cats, communities_community.pets_deposit_refundable, communities_community.pets_extra_rent, communities_community.pets_extra_rent_dogs, communities_community.pets_extra_rent_cats, communities_community.pets_fee, communities_community.pets_fee_dogs, communities_community.pets_fee_cats, communities_community.pets_restrictions, communities_community.pets_notes, communities_community.onsite_management, communities_community.onsite_maintenance, communities_community.utility_fees_cable, communities_community.utility_fees_electric, communities_community.utility_fees_gas, communities_community.utility_fees_telephone, communities_community.utility_fees_trash, communities_community.utility_fees_water, communities_community.tour_notes, communities_community.floorplans_notes, communities_community.special_offers, communities_community.property_selling_points, communities_community.apartment_features, communities_community.neighborhood_selling_points, communities_community.tags, communities_community.affordable_housing_offered, communities_community.affordable_housing_notes, communities_community.maintenance_notes, communities_community.escalation_process, communities_community.courtesy_patrol_company, communities_community.courtesy_patrol_number, communities_community.lock_out_policy, communities_community.electric_company, communities_community.gas_company, communities_community.telephone_company, communities_community.cable_company, communities_community.water_company, communities_community.internet_company, communities_community.neighborhood, communities_community.cable_paid_by_property, communities_community.internet_paid_by_property, communities_community.gas_paid_by_property, communities_community.pest_paid_by_property, communities_community.power_paid_by_property, communities_community.sewer_paid_by_property, communities_community.telephone_paid_by_property, communities_community.trash_paid_by_property, communities_community.full_size_washer_dryer, communities_community.full_size_washer_dryer_connections, communities_community.stackable_washer_dryer, communities_community.stackable_washer_dryer_connections, communities_community.own_washer_dryer_allowed, communities_community.leasing_deposit, communities_community.leasing_lease_term, communities_community.leasing_application_fee, communities_community.leasing_administrative_fee, t18.id, t18.password, t18.last_login, t18.is_superuser, t18.username, t18.first_name, t18.last_name, t18.email, t18.is_staff, t18.is_active, t18.date_joined, clients_touch.id, clients_touch.created_at, clients_touch.updated_at, clients_touch.client_id, clients_touch.source, clients_touch.source_type, clients_touch.discovery_source, clients_touch.medium, clients_touch.device, clients_touch.origin_source, clients_touch.campaign_info, clients_touch.category, clients_touch.website_app_id, clients_touch.website_session_id, clients_touch.website_user_id, accounts_managementcompany.name, accounts_managementcompany.account_type, accounts_managementcompany.datasource, accounts_managementcompany.source_mls, accounts_managementcompany.internal_database, accounts_managementcompany.is_manual_client, accounts_managementcompany.show_client_location_options, accounts_managementcompany.require_op_and_renter_incentives, accounts_managementcompany.is_active, accounts_managementcompany.external_source_id, accounts_managementcompany.market_id, accounts_managementcompany.pets_allowed, accounts_managementcompany.exclusive, accounts_managementcompany.default_private, accounts_managementcompany._market_units, accounts_managementcompany.announcements, accounts_managementcompany.policies, accounts_managementcompany.email_disclaimer, accounts_managementcompany.op_policy, accounts_managementcompany.pet_policy, accounts_managementcompany.application_fee, accounts_managementcompany.guarantor_policy, accounts_managementcompany.insurent_policy, accounts_managementcompany.walls_policy, accounts_managementcompany.standard_emergency_maintenance_list, accounts_managementcompany.phone_number, accounts_managementcompany.fax_number, accounts_managementcompany.email, accounts_managementcompany.website, accounts_managementcompany.old_address, accounts_managementcompany.street_address, accounts_managementcompany.address_unit, accounts_managementcompany.city, accounts_managementcompany.state, accounts_managementcompany.postal_code, accounts_managementcompany.listing_public_url_pattern, accounts_managementcompany.company_website_admin_url, accounts_managementcompany.internal_report_style, accounts_managementcompany.internal_report_order, accounts_managementcompany.inbound_email, accounts_managementcompany.custom_area_order, accounts_managementcompany.default_city, accounts_managementcompany.default_state, accounts_managementcompany.custom_statuses, accounts_managementcompany.custom_layouts, accounts_managementcompany.custom_referral_sources, accounts_managementcompany.widget_preferences, accounts_managementcompany.auth_key, accounts_managementcompany.hide_occupied_unit_numbers, accounts_managementcompany.hide_open_listing_addresses, accounts_managementcompany.include_listings_in_opens_filter, accounts_managementcompany.watermark_enabled, accounts_managementcompany.watermark, accounts_managementcompany.watermark_alpha, accounts_managementcompany.watermark_max_width, accounts_managementcompany.watermark_padding, accounts_managementcompany.watermark_align_vertical, accounts_managementcompany.watermark_align_horizontal, accounts_managementcompany.syndication_limit, accounts_managementcompany.listings_sharing, accounts_managementcompany.logo, accounts_managementcompany.primary_color, accounts_managementcompany.branding_override, accounts_managementcompany.application, accounts_managementcompany.application_original_filename, accounts_managementcompany.application_email_template, accounts_managementcompany.send_to_client_email_template, accounts_managementcompany.send_to_client_email_subject, accounts_managementcompany.subscribed_search_email_template, accounts_managementcompany.subscribed_search_email_subject, accounts_managementcompany.company_listings_agents_assignment, accounts_managementcompany.company_type, accounts_managementcompany.unit_extension_type, accounts_managementcompany.regular_user_edit_type, accounts_managementcompany.rls_read_access, accounts_managementcompany.rls_write_access, accounts_managementcompany.rls_write_active, accounts_managementcompany.idx_opt_out, accounts_managementcompany.mls_read_access, accounts_managementcompany.master_account_id, accounts_managementcompany.rebny_id, accounts_managementcompany.rls_managing_agency, accounts_managementcompany.listing_website_verification, accounts_managementcompany._default_role_id, accounts_managementcompany.users_can_assign_units_permission, accounts_managementcompany.analytics_collection_enabled, accounts_managementcompany.users_can_book_tours_within_lead_time, accounts_managementcompany.syndication_by_others_allowed, accounts_managementcompany.website_marketing_by_others_allowed, accounts_managementcompany.use_unit_type_in_syndication, accounts_managementcompany.track_usage, accounts_managementcompany.maximum_users, accounts_managementcompany.appointment_request_enabled, accounts_managementcompany.send_first_listing_notification, accounts_managementcompany.enable_craigslist_phone_tracking, accounts_managementcompany.new_incentives_enabled, accounts_managementcompany.internal_notes, accounts_managementcompany.api_syndication_lead_capture_enabled, accounts_managementcompany.enable_default_filter_groups, accounts_managementcompany.respect_prospect_sms_opted_in, accounts_managementcompany.system_tour_emails_enabled, accounts_managementcompany.agent_assignment_client_notifications_enabled, accounts_managementcompany.auto_response_enabled, accounts_managementcompany.auto_responder_agent_id, accounts_managementcompany.auto_send_disabled_weekday_start_time, accounts_managementcompany.auto_send_disabled_weekday_end_time, accounts_managementcompany.auto_send_disabled_weekend_start_time, accounts_managementcompany.auto_send_disabled_weekend_end_time, accounts_managementcompany.auto_send_padding_time, accounts_managementcompany.autoreply_use_templates, accounts_managementcompany.autoreply_template_subject, accounts_managementcompany.autoreply_template_primary, accounts_managementcompany.autoreply_template_pets, accounts_managementcompany.autoreply_template_apartment_search, accounts_managementcompany.autoreply_template_guarantors, accounts_managementcompany.autoreply_template_photo_request, accounts_managementcompany.autoreply_template_floorplan_request, accounts_managementcompany.autoreply_template_concessions, accounts_managementcompany.autoreply_template_utilities, accounts_managementcompany.autoreply_template_apartment_still_available, accounts_managementcompany.autoreply_template_roommate, accounts_managementcompany.autoreply_template_is_html, accounts_managementcompany.invite_to_apply_template_id, accounts_managementcompany.distribution_settings_enabled, accounts_managementcompany.enable_client_loss, accounts_managementcompany.optional_client_on_application, accounts_managementcompany.client_loss_reason_required, accounts_managementcompany.hide_broker_functionality, accounts_managementcompany.enable_send_listings_to_email_address, accounts_managementcompany.allow_merge_clients_between_groups, accounts_managementcompany.basic_crm_features_enabled, accounts_managementcompany.advanced_crm_features_enabled, accounts_managementcompany.incentives_marketing_description_enabled, accounts_managementcompany.uses_communities, accounts_managementcompany.resources_page_enabled, accounts_managementcompany.timezone, accounts_managementcompany.stripe_account_id, accounts_managementcompany.auto_assign_on_communication, accounts_managementcompany.message_composer_type, accounts_managementcompany.enable_quotes, accounts_managementcompany.guarantee, accounts_managementcompany.phone_agent_to_team_rollover_delay, accounts_managementcompany.outbound_call_recordings, accounts_managementcompany.created_at, accounts_managementcompany.updated_at, t20.id, t20.name, t20.company_id, t20."order", t20.leads_email_id, t20.central_leasing_team_id, t20.guided_tour_settings_id, t20.appointments_sms_alerts, t20.lead_widget_enabled, t20.lead_assignment, t20.lead_widget_settings, t20.lead_assignment_use_listing_agent, t20.lead_assignment_last_employee_id, t20.neighborhoods_config, t20.layout_config, t20.layout_options, t20.min_price_config, t20.max_price_config, t20.other_occupants_config, t20.lease_term_config, t20.current_postal_code_config, t20.client_location_config, t20.move_in_date_config, t20.pets_config, t20.amenities_config, t20.discovery_source_config, t20.notes_config, t20.broker_company_config, t20.broker_toggle_config, t20.assign_agent_config, t20.lead_source_config, t20.reason_for_move_config, t20.reason_for_move_options, t20.client_priorities_options, t20.system_tour_emails_enabled, t20.agent_assignment_client_notifications_enabled, t20.auto_response_enabled, t20.auto_responder_agent_id, t20.auto_send_use_company_disabled_times, t20.auto_send_disabled_weekday_start_time, t20.auto_send_disabled_weekday_end_time, t20.auto_send_disabled_weekend_start_time, t20.auto_send_disabled_weekend_end_time, t20.auto_send_padding_time, t20.autoreply_template_subject, t20.autoreply_template_primary, t20.autoreply_template_pets, t20.autoreply_template_apartment_search, t20.autoreply_template_guarantors, t20.autoreply_template_photo_request, t20.autoreply_template_floorplan_request, t20.autoreply_template_concessions, t20.autoreply_template_utilities, t20.autoreply_template_apartment_still_available, t20.autoreply_template_roommate, t20.timezone, t20.lead_emails_streeteasy_zumper_renthop_realtor_enabled, t20.lead_emails_zillow_enabled, t20.lead_emails_lead_widget_contact_form_enabled, t20.lead_emails_nestcard_enabled, t20.lead_emails_phone_calls_enabled, t20.prevent_tours_outside_of_team_hours, t20.disallow_manual_appointment_overlap, t20.default_phone_number_id
  • Sort Method: quicksort Memory: 82kB
4. 0.722 99.001 ↓ 38.0 38 1

Nested Loop Left Join (cost=151.23..655.60 rows=1 width=5,527) (actual time=3.444..99.001 rows=38 loops=1)

5. 0.774 97.975 ↓ 38.0 38 1

Nested Loop Left Join (cost=150.95..651.84 rows=1 width=5,243) (actual time=3.405..97.975 rows=38 loops=1)

6. 0.742 96.669 ↓ 38.0 38 1

Nested Loop Left Join (cost=150.53..643.60 rows=1 width=5,169) (actual time=3.360..96.669 rows=38 loops=1)

7. 0.803 95.585 ↓ 38.0 38 1

Nested Loop Left Join (cost=150.25..643.01 rows=1 width=5,021) (actual time=3.315..95.585 rows=38 loops=1)

8. 0.685 94.554 ↓ 38.0 38 1

Nested Loop Left Join (cost=149.97..642.68 rows=1 width=3,445) (actual time=3.281..94.554 rows=38 loops=1)

9. 0.755 93.565 ↓ 38.0 38 1

Nested Loop Left Join (cost=149.54..638.41 rows=1 width=3,145) (actual time=3.248..93.565 rows=38 loops=1)

10. 0.669 92.392 ↓ 38.0 38 1

Nested Loop Left Join (cost=149.26..637.84 rows=1 width=2,276) (actual time=3.211..92.392 rows=38 loops=1)

11. 0.713 91.229 ↓ 38.0 38 1

Nested Loop Left Join (cost=148.97..637.53 rows=1 width=2,268) (actual time=3.173..91.229 rows=38 loops=1)

12. 0.754 90.060 ↓ 38.0 38 1

Nested Loop Left Join (cost=148.55..636.99 rows=1 width=2,051) (actual time=3.132..90.060 rows=38 loops=1)

13. 0.723 88.926 ↓ 38.0 38 1

Nested Loop Left Join (cost=148.26..636.66 rows=1 width=1,814) (actual time=3.094..88.926 rows=38 loops=1)

14. 21.487 87.861 ↓ 38.0 38 1

Nested Loop Left Join (cost=148.11..636.49 rows=1 width=1,785) (actual time=3.053..87.861 rows=38 loops=1)

  • Join Filter: (clients_client.discovery_source = t10.id)
  • Rows Removed by Join Filter: 3420
15. 19.417 46.234 ↓ 38.0 38 1

Nested Loop Left Join (cost=148.11..633.47 rows=1 width=1,751) (actual time=1.899..46.234 rows=38 loops=1)

  • Join Filter: (clients_client.lead_source = clients_discoverysource.id)
  • Rows Removed by Join Filter: 3122
16. 0.669 7.931 ↓ 38.0 38 1

Nested Loop Left Join (cost=148.11..630.44 rows=1 width=1,717) (actual time=0.827..7.931 rows=38 loops=1)

17. 0.801 6.844 ↓ 38.0 38 1

Nested Loop Left Join (cost=147.69..622.07 rows=1 width=1,329) (actual time=0.783..6.844 rows=38 loops=1)

18. 1.114 5.739 ↓ 38.0 38 1

Nested Loop Left Join (cost=147.41..618.31 rows=1 width=1,049) (actual time=0.751..5.739 rows=38 loops=1)

  • Filter: ((clients_client_agents.user_id IS NOT NULL) OR (clients_client.group_id IS NULL))
19. 1.203 3.827 ↓ 38.0 38 1

Nested Loop (cost=146.99..609.93 rows=1 width=1,049) (actual time=0.715..3.827 rows=38 loops=1)

20. 0.685 1.978 ↓ 38.0 38 1

Hash Join (cost=146.70..601.62 rows=1 width=579) (actual time=0.671..1.978 rows=38 loops=1)

  • Hash Cond: (clients_client.id = t6.client_id)
21. 0.684 0.684 ↓ 1.2 68 1

Index Scan using clients_client_brokerage_id on clients_client (cost=0.42..455.18 rows=59 width=579) (actual time=0.023..0.684 rows=68 loops=1)

  • Index Cond: (brokerage_id = 18759)
  • Filter: ((status <> ALL ('{50,70}'::integer[])) AND (status = 10))
  • Rows Removed by Filter: 6
22. 0.249 0.609 ↑ 1.6 38 1

Hash (cost=145.53..145.53 rows=60 width=4) (actual time=0.596..0.609 rows=38 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 10kB
23. 0.360 0.360 ↑ 1.6 38 1

Index Scan using clients_client_agents_user_id on clients_client_agents t6 (cost=0.42..145.53 rows=60 width=4) (actual time=0.023..0.360 rows=38 loops=1)

  • Index Cond: (user_id = 27610)
24. 0.646 0.646 ↑ 1.0 1 38

Index Scan using accounts_managementcompany_pkey on accounts_managementcompany (cost=0.29..8.30 rows=1 width=470) (actual time=0.009..0.017 rows=1 loops=38)

  • Index Cond: (id = 18759)
25. 0.798 0.798 ↑ 1.0 1 38

Index Scan using clients_client_agents_client_id on clients_client_agents (cost=0.42..8.37 rows=1 width=8) (actual time=0.014..0.021 rows=1 loops=38)

  • Index Cond: (clients_client.id = client_id)
26. 0.304 0.304 ↓ 0.0 0 38

Index Scan using accounts_employeegroup_pkey on accounts_employeegroup (cost=0.28..3.75 rows=1 width=280) (actual time=0.007..0.008 rows=0 loops=38)

  • Index Cond: (clients_client.group_id = id)
27. 0.418 0.418 ↑ 1.0 1 38

Index Scan using messenger_communication_pkey on messenger_communication (cost=0.42..8.37 rows=1 width=388) (actual time=0.011..0.011 rows=1 loops=38)

  • Index Cond: (clients_client.last_message_id = id)
28. 18.886 18.886 ↑ 1.1 82 38

Seq Scan on clients_discoverysource (cost=0.00..1.90 rows=90 width=34) (actual time=0.008..0.497 rows=82 loops=38)

29. 20.140 20.140 ↑ 1.0 90 38

Seq Scan on clients_discoverysource t10 (cost=0.00..1.90 rows=90 width=34) (actual time=0.008..0.530 rows=90 loops=38)

30. 0.342 0.342 ↑ 1.0 1 38

Index Scan using django_content_type_pkey on django_content_type (cost=0.14..0.16 rows=1 width=29) (actual time=0.008..0.009 rows=1 loops=38)

  • Index Cond: (messenger_communication.polymorphic_ctype_id = id)
31. 0.380 0.380 ↓ 0.0 0 38

Index Scan using messenger_action_pkey1 on messenger_action (cost=0.29..0.33 rows=1 width=237) (actual time=0.009..0.010 rows=0 loops=38)

  • Index Cond: (messenger_communication.id = communication_ptr_id)
32. 0.456 0.456 ↓ 0.0 0 38

Index Scan using messenger_smsornylasemailmessage_pkey on messenger_smsornylasemailmessage (cost=0.42..0.54 rows=1 width=217) (actual time=0.011..0.012 rows=0 loops=38)

  • Index Cond: (messenger_communication.id = communication_ptr_id)
33. 0.494 0.494 ↑ 1.0 1 38

Index Scan using messenger_phonecallrecord_pkey on messenger_phonecallrecord (cost=0.29..0.31 rows=1 width=8) (actual time=0.010..0.013 rows=1 loops=38)

  • Index Cond: (messenger_communication.id = communication_ptr_id)
34. 0.418 0.418 ↑ 1.0 1 38

Index Scan using telephony_new_phonecall_pkey on telephony_phonecall (cost=0.29..0.58 rows=1 width=869) (actual time=0.010..0.011 rows=1 loops=38)

  • Index Cond: (messenger_phonecallrecord.phone_call_id = id)
35. 0.304 0.304 ↓ 0.0 0 38

Index Scan using units_building_pkey on units_building (cost=0.43..4.27 rows=1 width=300) (actual time=0.007..0.008 rows=0 loops=38)

  • Index Cond: (telephony_phonecall.building_id = id)
36. 0.228 0.228 ↓ 0.0 0 38

Index Scan using communities_community_pkey on communities_community (cost=0.28..0.32 rows=1 width=1,576) (actual time=0.006..0.006 rows=0 loops=38)

  • Index Cond: (telephony_phonecall.community_id = id)
37. 0.342 0.342 ↑ 1.0 1 38

Index Scan using auth_user_pkey on auth_user t18 (cost=0.29..0.60 rows=1 width=148) (actual time=0.008..0.009 rows=1 loops=38)

  • Index Cond: (telephony_phonecall.user_id = id)
38. 0.532 0.532 ↑ 1.0 1 38

Index Scan using clients_touch_pkey on clients_touch (cost=0.42..8.23 rows=1 width=74) (actual time=0.014..0.014 rows=1 loops=38)

  • Index Cond: (clients_client.first_touch_id = id)
39. 0.304 0.304 ↓ 0.0 0 38

Index Scan using accounts_employeegroup_pkey on accounts_employeegroup t20 (cost=0.28..3.75 rows=1 width=280) (actual time=0.007..0.008 rows=0 loops=38)

  • Index Cond: (clients_client.action_assigned_to_id = id)
Planning time : 1,662.968 ms
Execution time : 168.907 ms