PgHero
No long running queries
Connections healthy 12
Vacuuming healthy
No columns near integer overflow
No invalid indexes or constraints
147 duplicate indexes
5 suggested indexes
40 slow queries

Duplicate Indexes

These indexes exist, but aren’t needed. Remove them for faster writes.

rails generate migration remove_unneeded_indexes

And paste

remove_index :account_account, name: "account_account_code_index", column: :code
remove_index :account_account_account_tag, name: "account_account_account_tag_account_account_id_idx", column: :account_account_id
remove_index :account_account_financial_report, name: "account_account_financial_report_report_line_id_idx", column: :report_line_id
remove_index :account_account_financial_report_type, name: "account_account_financial_report_type_report_id_idx", column: :report_id
remove_index :account_account_tag_account_tax_template_rel, name: "account_account_tag_account_tax_tem_account_tax_template_id_idx", column: :account_tax_template_id
remove_index :account_account_tax_default_rel, name: "account_account_tax_default_rel_account_id_idx", column: :account_id
remove_index :account_account_template_account_tag, name: "account_account_template_accoun_account_account_template_id_idx", column: :account_account_template_id
remove_index :account_account_template_tax_rel, name: "account_account_template_tax_rel_account_id_idx", column: :account_id
remove_index :account_account_type_rel, name: "account_account_type_rel_journal_id_idx", column: :journal_id
remove_index :account_aged_trial_balance_account_journal_rel, name: "account_aged_trial_balance_ac_account_aged_trial_balance_id_idx", column: :account_aged_trial_balance_id
remove_index :account_analytic_account_tag_rel, name: "account_analytic_account_tag_rel_account_id_idx", column: :account_id
remove_index :account_analytic_line_tag_rel, name: "account_analytic_line_tag_rel_line_id_idx", column: :line_id
remove_index :account_analytic_tag_account_invoice_line_rel, name: "account_analytic_tag_account_invoic_account_invoice_line_id_idx", column: :account_invoice_line_id
remove_index :account_analytic_tag_account_move_line_rel, name: "account_analytic_tag_account_move_line_account_move_line_id_idx", column: :account_move_line_id
remove_index :account_analytic_tag_purchase_order_line_rel, name: "account_analytic_tag_purchase_order__purchase_order_line_id_idx", column: :purchase_order_line_id
remove_index :account_analytic_tag_sale_order_line_rel, name: "account_analytic_tag_sale_order_line_rel_sale_order_line_id_idx", column: :sale_order_line_id
remove_index :account_balance_report_journal_rel, name: "account_balance_report_journal_rel_account_id_idx", column: :account_id
remove_index :account_common_account_report_account_journal_rel, name: "account_common_account_report_account_common_account_report_idx", column: :account_common_account_report_id
remove_index :account_common_journal_report_account_journal_rel, name: "account_common_journal_report_account_common_journal_report_idx", column: :account_common_journal_report_id
remove_index :account_common_partner_report_account_journal_rel, name: "account_common_partner_report_account_common_partner_report_idx", column: :account_common_partner_report_id
remove_index :account_common_report_account_journal_rel, name: "account_common_report_account_jour_account_common_report_id_idx", column: :account_common_report_id
remove_index :account_fiscal_position_res_country_state_rel, name: "account_fiscal_position_res_coun_account_fiscal_position_id_idx", column: :account_fiscal_position_id
remove_index :account_fiscal_position_template_res_country_state_rel, name: "account_fiscal_position_templ_account_fiscal_position_templ_idx", column: :account_fiscal_position_template_id
remove_index :account_invoice_account_move_line_rel, name: "account_invoice_account_move_line_rel_account_invoice_id_idx", column: :account_invoice_id
remove_index :account_invoice_account_register_payments_rel, name: "account_invoice_account_regist_account_register_payments_id_idx", column: :account_register_payments_id
remove_index :account_invoice_line_tax, name: "account_invoice_line_tax_invoice_line_id_idx", column: :invoice_line_id
remove_index :account_invoice_payment_rel, name: "account_invoice_payment_rel_payment_id_idx", column: :payment_id
remove_index :account_invoice_purchase_order_rel, name: "account_invoice_purchase_order_rel_purchase_order_id_idx", column: :purchase_order_id
remove_index :account_journal_account_print_journal_rel, name: "account_journal_account_print_jour_account_print_journal_id_idx", column: :account_print_journal_id
remove_index :account_journal_account_report_partner_ledger_rel, name: "account_journal_account_repor_account_report_partner_ledger_idx", column: :account_report_partner_ledger_id
remove_index :account_journal_account_tax_report_rel, name: "account_journal_account_tax_report_re_account_tax_report_id_idx", column: :account_tax_report_id
remove_index :account_journal_accounting_report_rel, name: "account_journal_accounting_report_rel_accounting_report_id_idx", column: :accounting_report_id
remove_index :account_journal_inbound_payment_method_rel, name: "account_journal_inbound_payment_method_rel_journal_id_idx", column: :journal_id
remove_index :account_journal_outbound_payment_method_rel, name: "account_journal_outbound_payment_method_rel_journal_id_idx", column: :journal_id
remove_index :account_journal_type_rel, name: "account_journal_type_rel_journal_id_idx", column: :journal_id
remove_index :account_move_line_account_tax_rel, name: "account_move_line_account_tax_rel_account_move_line_id_idx", column: :account_move_line_id
remove_index :account_report_general_ledger_journal_rel, name: "account_report_general_ledger_journal_rel_account_id_idx", column: :account_id
remove_index :account_tax_account_tag, name: "account_tax_account_tag_account_tax_id_idx", column: :account_tax_id
remove_index :account_tax_filiation_rel, name: "account_tax_filiation_rel_parent_tax_idx", column: :parent_tax
remove_index :account_tax_purchase_order_line_rel, name: "account_tax_purchase_order_line_rel_purchase_order_line_id_idx", column: :purchase_order_line_id
remove_index :account_tax_sale_advance_payment_inv_rel, name: "account_tax_sale_advance_paymen_sale_advance_payment_inv_id_idx", column: :sale_advance_payment_inv_id
remove_index :account_tax_sale_order_line_rel, name: "account_tax_sale_order_line_rel_sale_order_line_id_idx", column: :sale_order_line_id
remove_index :account_tax_template_filiation_rel, name: "account_tax_template_filiation_rel_parent_tax_idx", column: :parent_tax
remove_index :base_partner_merge_automatic_wizard_res_partner_rel, name: "base_partner_merge_automatic__base_partner_merge_automatic__idx", column: :base_partner_merge_automatic_wizard_id
remove_index :brand_food_platform_rel, name: "brand_food_platform_rel_platform_id_idx", column: :platform_id
remove_index :bus_presence, name: "bus_presence_user_id_index", column: :user_id
remove_index :calendar_alarm_calendar_event_rel, name: "calendar_alarm_calendar_event_rel_calendar_event_id_idx", column: :calendar_event_id
remove_index :calendar_event_res_partner_rel, name: "calendar_event_res_partner_rel_calendar_event_id_idx", column: :calendar_event_id
remove_index :change_request_attachment_rel, name: "change_request_attachment_rel_change_request_id_idx", column: :change_request_id
remove_index :combo_attribute_line_product_attribute_value_rel, name: "combo_attribute_line_product_attrib_combo_attribute_line_id_idx", column: :combo_attribute_line_id
remove_index :crm_lead2opportunity_partner_mass_res_users_rel, name: "crm_lead2opportunity_partner__crm_lead2opportunity_partner__idx", column: :crm_lead2opportunity_partner_mass_id
remove_index :crm_lead_crm_lead2opportunity_partner_mass_rel, name: "crm_lead_crm_lead2opportunity_crm_lead2opportunity_partner_idx1", column: :crm_lead2opportunity_partner_mass_id
remove_index :crm_lead_crm_lead2opportunity_partner_rel, name: "crm_lead_crm_lead2opportunity_crm_lead2opportunity_partner__idx", column: :crm_lead2opportunity_partner_id
remove_index :crm_lead_tag_rel, name: "crm_lead_tag_rel_lead_id_idx", column: :lead_id
remove_index :decimal_precision, name: "decimal_precision_name_index", column: :name
remove_index :delivery_order_line, name: "delivery_order_line_order_id_index", column: :order_id
remove_index :delivery_order_print_product_category_rel, name: "delivery_order_print_product_catego_delivery_order_print_id_idx", column: :delivery_order_print_id
remove_index :delivery_order_print_stock_warehouse_rel, name: "delivery_order_print_stock_warehous_delivery_order_print_id_idx", column: :delivery_order_print_id
remove_index :delivery_order_swk_merge_do_rel, name: "delivery_order_swk_merge_do_rel_swk_merge_do_id_idx", column: :swk_merge_do_id
remove_index :email_template_attachment_rel, name: "email_template_attachment_rel_email_template_id_idx", column: :email_template_id
remove_index :email_template_preview_res_partner_rel, name: "email_template_preview_res_partne_email_template_preview_id_idx", column: :email_template_preview_id
remove_index :food_profile_line_food_profile_tag_rel, name: "food_profile_line_food_profile_tag_rel_food_profile_line_id_idx", column: :food_profile_line_id
remove_index :helpdesk_ticket_attachment_rel, name: "helpdesk_ticket_attachment_rel_submit_helpdesk_ticket_id_idx", column: :submit_helpdesk_ticket_id
remove_index :invoice_reconciliation_report_attachment_rel, name: "invoice_reconciliation_report_invoice_reconciliation_report_idx", column: :invoice_reconciliation_report_id
remove_index :ir_act_server_mail_channel_rel, name: "ir_act_server_mail_channel_rel_ir_act_server_id_idx", column: :ir_act_server_id
remove_index :ir_act_server_res_partner_rel, name: "ir_act_server_res_partner_rel_ir_act_server_id_idx", column: :ir_act_server_id
remove_index :ir_act_window_group_rel, name: "ir_act_window_group_rel_act_id_idx", column: :act_id
remove_index :ir_attachment_swk_cr_attachment_rel, name: "ir_attachment_swk_cr_attachment_rel_swk_cr_attachment_id_idx", column: :swk_cr_attachment_id
remove_index :ir_config_parameter, name: "ir_config_parameter_key_index", column: :key
remove_index :ir_model, name: "ir_model_model_index", column: :model
remove_index :ir_model_constraint, name: "ir_model_constraint_name_index", column: :name
remove_index :ir_model_fields, name: "ir_model_fields_model_index", column: :model
remove_index :ir_model_fields_group_rel, name: "ir_model_fields_group_rel_field_id_idx", column: :field_id
remove_index :ir_model_save_dialog, name: "ir_model_save_dialog_model_id_index", column: :model_id
remove_index :ir_module_module, name: "ir_module_module_name_index", column: :name
remove_index :ir_ui_menu_group_rel, name: "ir_ui_menu_group_rel_menu_id_idx", column: :menu_id
remove_index :ir_ui_view, name: "ir_ui_view_model_index", column: :model
remove_index :ir_ui_view_custom, name: "ir_ui_view_custom_user_id_index", column: :user_id
remove_index :ir_ui_view_group_rel, name: "ir_ui_view_group_rel_view_id_idx", column: :view_id
remove_index :mail_activity_rel, name: "mail_activity_rel_activity_id_idx", column: :activity_id
remove_index :mail_channel_mail_wizard_invite_rel, name: "mail_channel_mail_wizard_invite_rel_mail_wizard_invite_id_idx", column: :mail_wizard_invite_id
remove_index :mail_channel_res_groups_rel, name: "mail_channel_res_groups_rel_mail_channel_id_idx", column: :mail_channel_id
remove_index :mail_compose_message_ir_attachments_rel, name: "mail_compose_message_ir_attachments_rel_wizard_id_idx", column: :wizard_id
remove_index :mail_compose_message_res_partner_rel, name: "mail_compose_message_res_partner_rel_wizard_id_idx", column: :wizard_id
remove_index :mail_followers, name: "mail_followers_res_model_index", column: :res_model
remove_index :mail_followers_mail_message_subtype_rel, name: "mail_followers_mail_message_subtype_rel_mail_followers_id_idx", column: :mail_followers_id
remove_index :mail_mail_res_partner_rel, name: "mail_mail_res_partner_rel_mail_mail_id_idx", column: :mail_mail_id
remove_index :mail_message, name: "mail_message_model_index", column: :model
remove_index :mail_message_mail_channel_rel, name: "mail_message_mail_channel_rel_mail_message_id_idx", column: :mail_message_id
remove_index :mail_message_res_partner_needaction_rel, name: "mail_message_res_partner_needaction_rel_res_partner_id_index", column: :res_partner_id
remove_index :mail_message_res_partner_rel, name: "mail_message_res_partner_rel_mail_message_id_idx", column: :mail_message_id
remove_index :mail_message_res_partner_starred_rel, name: "mail_message_res_partner_starred_rel_mail_message_id_idx", column: :mail_message_id
remove_index :mail_wizard_invite_res_partner_rel, name: "mail_wizard_invite_res_partner_rel_mail_wizard_invite_id_idx", column: :mail_wizard_invite_id
remove_index :meeting_category_rel, name: "meeting_category_rel_event_id_idx", column: :event_id
remove_index :merge_opportunity_rel, name: "merge_opportunity_rel_merge_id_idx", column: :merge_id
remove_index :message_attachment_rel, name: "message_attachment_rel_message_id_idx", column: :message_id
remove_index :mrp_bom_line_product_attribute_value_rel, name: "mrp_bom_line_product_attribute_value_rel_mrp_bom_line_id_idx", column: :mrp_bom_line_id
remove_index :payment_acquirer_payment_icon_rel, name: "payment_acquirer_payment_icon_rel_payment_acquirer_id_idx", column: :payment_acquirer_id
remove_index :payment_country_rel, name: "payment_country_rel_payment_id_idx", column: :payment_id
remove_index :printing_printer_swk_kitchen_config_rel, name: "printing_printer_swk_kitchen_config_r_swk_kitchen_config_id_idx", column: :swk_kitchen_config_id
remove_index :product_attribute_line_product_attribute_value_rel, name: "product_attribute_line_product_at_product_attribute_line_id_idx", column: :product_attribute_line_id
remove_index :product_attribute_value_product_configurator_attribute_rel, name: "product_attribute_value_produ_product_configurator_attribut_idx", column: :product_configurator_attribute_id
remove_index :product_attribute_value_product_product_rel, name: "product_attribute_value_product_product__product_product_id_idx", column: :product_product_id
remove_index :product_supplier_taxes_rel, name: "product_supplier_taxes_rel_prod_id_idx", column: :prod_id
remove_index :product_taxes_rel, name: "product_taxes_rel_prod_id_idx", column: :prod_id
remove_index :purchase_order_stock_picking_rel, name: "purchase_order_stock_picking_rel_purchase_order_id_idx", column: :purchase_order_id
remove_index :queue_job_queue_jobs_to_done_rel, name: "queue_job_queue_jobs_to_done_rel_queue_jobs_to_done_id_idx", column: :queue_jobs_to_done_id
remove_index :queue_job_queue_requeue_job_rel, name: "queue_job_queue_requeue_job_rel_queue_requeue_job_id_idx", column: :queue_requeue_job_id
remove_index :rel_modules_langexport, name: "rel_modules_langexport_wiz_id_idx", column: :wiz_id
remove_index :rel_server_actions, name: "rel_server_actions_server_id_idx", column: :server_id
remove_index :res_company_swk_day_rel, name: "res_company_swk_day_rel_res_company_id_idx", column: :res_company_id
remove_index :res_company_users_rel, name: "res_company_users_rel_cid_idx", column: :cid
remove_index :res_country_group_pricelist_rel, name: "res_country_group_pricelist_rel_pricelist_id_idx", column: :pricelist_id
remove_index :res_country_res_country_group_rel, name: "res_country_res_country_group_rel_res_country_id_idx", column: :res_country_id
remove_index :res_currency_rate, name: "res_currency_rate_name_index", column: :name
remove_index :res_groups, name: "res_groups_category_id_index", column: :category_id
remove_index :res_groups_implied_rel, name: "res_groups_implied_rel_gid_idx", column: :gid
remove_index :res_groups_report_rel, name: "res_groups_report_rel_uid_idx", column: :uid
remove_index :res_groups_users_rel, name: "res_groups_users_rel_gid_idx", column: :gid
remove_index :res_partner_res_partner_category_rel, name: "res_partner_res_partner_category_rel_category_id_idx", column: :category_id
remove_index :res_users_stock_warehouse_rel, name: "res_users_stock_warehouse_rel_res_users_id_idx", column: :res_users_id
remove_index :rule_group_rel, name: "rule_group_rel_rule_group_id_idx", column: :rule_group_id
remove_index :sale_order_line_invoice_rel, name: "sale_order_line_invoice_rel_invoice_line_id_idx", column: :invoice_line_id
remove_index :sale_order_tag_rel, name: "sale_order_tag_rel_order_id_idx", column: :order_id
remove_index :stock_location_route_categ, name: "stock_location_route_categ_route_id_idx", column: :route_id
remove_index :stock_location_route_move, name: "stock_location_route_move_move_id_idx", column: :move_id
remove_index :stock_move, name: "stock_move_product_id_index", column: :product_id
remove_index :stock_move_line_consume_rel, name: "stock_move_line_consume_rel_consume_line_id_idx", column: :consume_line_id
remove_index :stock_move_move_rel, name: "stock_move_move_rel_move_orig_id_idx", column: :move_orig_id
remove_index :stock_picking, name: "stock_picking_name_index", column: :name
remove_index :stock_picking_backorder_rel, name: "stock_picking_backorder_rel_stock_backorder_confirmation_id_idx", column: :stock_backorder_confirmation_id
remove_index :stock_picking_transfer_rel, name: "stock_picking_transfer_rel_stock_immediate_transfer_id_idx", column: :stock_immediate_transfer_id
remove_index :stock_route_product, name: "stock_route_product_route_id_idx", column: :route_id
remove_index :stock_route_warehouse, name: "stock_route_warehouse_route_id_idx", column: :route_id
remove_index :stock_warehouse, name: "stock_warehouse_name_index", column: :name
remove_index :stock_warehouse_swk_menu_rel, name: "stock_warehouse_swk_menu_rel_swk_menu_id_idx", column: :swk_menu_id
remove_index :stock_warehouse_talabat_menu_snooze_rel, name: "stock_warehouse_talabat_menu_snooze__talabat_menu_snooze_id_idx", column: :talabat_menu_snooze_id
remove_index :stock_wh_resupply_table, name: "stock_wh_resupply_table_supplied_wh_id_idx", column: :supplied_wh_id
remove_index :swk_brand_hours_swk_day_rel, name: "swk_brand_hours_swk_day_rel_swk_brand_hours_id_idx", column: :swk_brand_hours_id
remove_index :swk_brand_swk_day_rel, name: "swk_brand_swk_day_rel_swk_brand_id_idx", column: :swk_brand_id
remove_index :swk_brand_swk_menu_item_rel, name: "swk_brand_swk_menu_item_rel_swk_brand_id_idx", column: :swk_brand_id
remove_index :swk_menu_item_talabat_menu_snooze_rel, name: "swk_menu_item_talabat_menu_snooze_re_talabat_menu_snooze_id_idx", column: :talabat_menu_snooze_id
remove_index :swk_menu_item_upload_menu_item_rel, name: "swk_menu_item_upload_menu_item_rel_upload_menu_item_id_idx", column: :upload_menu_item_id
remove_index :swk_menu_swk_menu_item_rel, name: "swk_menu_swk_menu_item_rel_swk_menu_id_idx", column: :swk_menu_id
remove_index :swk_merge_pt_swk_production_ticket_rel, name: "swk_merge_pt_swk_production_ticket_rel_swk_merge_pt_id_idx", column: :swk_merge_pt_id
remove_index :team_favorite_user_rel, name: "team_favorite_user_rel_team_id_idx", column: :team_id
remove_index :zomato_recommended, name: "zomato_recommended_menu_id_idx", column: :menu_id
Details
On account_account
account_account_code_index (code)
is covered by
account_account_code_company_uniq (code, company_id)
On account_account_account_tag
account_account_account_tag_account_account_id_idx (account_account_id)
is covered by
account_account_account_tag_account_account_id_account_acco_key (account_account_id, account_account_tag_id)
On account_account_financial_report
account_account_financial_report_report_line_id_idx (report_line_id)
is covered by
account_account_financial_report_report_line_id_account_id_key (report_line_id, account_id)
On account_account_financial_report_type
account_account_financial_report_type_report_id_idx (report_id)
is covered by
account_account_financial_report__report_id_account_type_id_key (report_id, account_type_id)
On account_account_tag_account_tax_template_rel
account_account_tag_account_tax_tem_account_tax_template_id_idx (account_tax_template_id)
is covered by
account_account_tag_account_t_account_tax_template_id_accou_key (account_tax_template_id, account_account_tag_id)
On account_account_tax_default_rel
account_account_tax_default_rel_account_id_idx (account_id)
is covered by
account_account_tax_default_rel_account_id_tax_id_key (account_id, tax_id)
On account_account_template_account_tag
account_account_template_accoun_account_account_template_id_idx (account_account_template_id)
is covered by
account_account_template_acco_account_account_template_id_a_key (account_account_template_id, account_account_tag_id)
On account_account_template_tax_rel
account_account_template_tax_rel_account_id_idx (account_id)
is covered by
account_account_template_tax_rel_account_id_tax_id_key (account_id, tax_id)
On account_account_type_rel
account_account_type_rel_journal_id_idx (journal_id)
is covered by
account_account_type_rel_journal_id_account_id_key (journal_id, account_id)
On account_aged_trial_balance_account_journal_rel
account_aged_trial_balance_ac_account_aged_trial_balance_id_idx (account_aged_trial_balance_id)
is covered by
account_aged_trial_balance_ac_account_aged_trial_balance_id_key (account_aged_trial_balance_id, account_journal_id)
On account_analytic_account_tag_rel
account_analytic_account_tag_rel_account_id_idx (account_id)
is covered by
account_analytic_account_tag_rel_account_id_tag_id_key (account_id, tag_id)
On account_analytic_line_tag_rel
account_analytic_line_tag_rel_line_id_idx (line_id)
is covered by
account_analytic_line_tag_rel_line_id_tag_id_key (line_id, tag_id)
On account_analytic_tag_account_invoice_line_rel
account_analytic_tag_account_invoic_account_invoice_line_id_idx (account_invoice_line_id)
is covered by
account_analytic_tag_account__account_invoice_line_id_accou_key (account_invoice_line_id, account_analytic_tag_id)
On account_analytic_tag_account_move_line_rel
account_analytic_tag_account_move_line_account_move_line_id_idx (account_move_line_id)
is covered by
account_analytic_tag_account__account_move_line_id_account__key (account_move_line_id, account_analytic_tag_id)
On account_analytic_tag_purchase_order_line_rel
account_analytic_tag_purchase_order__purchase_order_line_id_idx (purchase_order_line_id)
is covered by
account_analytic_tag_purchase_purchase_order_line_id_accoun_key (purchase_order_line_id, account_analytic_tag_id)
On account_analytic_tag_sale_order_line_rel
account_analytic_tag_sale_order_line_rel_sale_order_line_id_idx (sale_order_line_id)
is covered by
account_analytic_tag_sale_ord_sale_order_line_id_account_an_key (sale_order_line_id, account_analytic_tag_id)
On account_balance_report_journal_rel
account_balance_report_journal_rel_account_id_idx (account_id)
is covered by
account_balance_report_journal_rel_account_id_journal_id_key (account_id, journal_id)
On account_common_account_report_account_journal_rel
account_common_account_report_account_common_account_report_idx (account_common_account_report_id)
is covered by
account_common_account_report_account_common_account_report_key (account_common_account_report_id, account_journal_id)
On account_common_journal_report_account_journal_rel
account_common_journal_report_account_common_journal_report_idx (account_common_journal_report_id)
is covered by
account_common_journal_report_account_common_journal_report_key (account_common_journal_report_id, account_journal_id)
On account_common_partner_report_account_journal_rel
account_common_partner_report_account_common_partner_report_idx (account_common_partner_report_id)
is covered by
account_common_partner_report_account_common_partner_report_key (account_common_partner_report_id, account_journal_id)
On account_common_report_account_journal_rel
account_common_report_account_jour_account_common_report_id_idx (account_common_report_id)
is covered by
account_common_report_account_account_common_report_id_acco_key (account_common_report_id, account_journal_id)
On account_fiscal_position_res_country_state_rel
account_fiscal_position_res_coun_account_fiscal_position_id_idx (account_fiscal_position_id)
is covered by
account_fiscal_position_res_c_account_fiscal_position_id_re_key (account_fiscal_position_id, res_country_state_id)
On account_fiscal_position_template_res_country_state_rel
account_fiscal_position_templ_account_fiscal_position_templ_idx (account_fiscal_position_template_id)
is covered by
account_fiscal_position_templ_account_fiscal_position_templ_key (account_fiscal_position_template_id, res_country_state_id)
On account_invoice_account_move_line_rel
account_invoice_account_move_line_rel_account_invoice_id_idx (account_invoice_id)
is covered by
account_invoice_account_move__account_invoice_id_account_mo_key (account_invoice_id, account_move_line_id)
On account_invoice_account_register_payments_rel
account_invoice_account_regist_account_register_payments_id_idx (account_register_payments_id)
is covered by
account_invoice_account_regis_account_register_payments_id__key (account_register_payments_id, account_invoice_id)
On account_invoice_line_tax
account_invoice_line_tax_invoice_line_id_idx (invoice_line_id)
is covered by
account_invoice_line_tax_invoice_line_id_tax_id_key (invoice_line_id, tax_id)
On account_invoice_payment_rel
account_invoice_payment_rel_payment_id_idx (payment_id)
is covered by
account_invoice_payment_rel_payment_id_invoice_id_key (payment_id, invoice_id)
On account_invoice_purchase_order_rel
account_invoice_purchase_order_rel_purchase_order_id_idx (purchase_order_id)
is covered by
account_invoice_purchase_orde_purchase_order_id_account_inv_key (purchase_order_id, account_invoice_id)
On account_journal_account_print_journal_rel
account_journal_account_print_jour_account_print_journal_id_idx (account_print_journal_id)
is covered by
account_journal_account_print_account_print_journal_id_acco_key (account_print_journal_id, account_journal_id)
On account_journal_account_report_partner_ledger_rel
account_journal_account_repor_account_report_partner_ledger_idx (account_report_partner_ledger_id)
is covered by
account_journal_account_repor_account_report_partner_ledger_key (account_report_partner_ledger_id, account_journal_id)
On account_journal_account_tax_report_rel
account_journal_account_tax_report_re_account_tax_report_id_idx (account_tax_report_id)
is covered by
account_journal_account_tax_r_account_tax_report_id_account_key (account_tax_report_id, account_journal_id)
On account_journal_accounting_report_rel
account_journal_accounting_report_rel_accounting_report_id_idx (accounting_report_id)
is covered by
account_journal_accounting_re_accounting_report_id_account__key (accounting_report_id, account_journal_id)
On account_journal_inbound_payment_method_rel
account_journal_inbound_payment_method_rel_journal_id_idx (journal_id)
is covered by
account_journal_inbound_payme_journal_id_inbound_payment_me_key (journal_id, inbound_payment_method)
On account_journal_outbound_payment_method_rel
account_journal_outbound_payment_method_rel_journal_id_idx (journal_id)
is covered by
account_journal_outbound_paym_journal_id_outbound_payment_m_key (journal_id, outbound_payment_method)
On account_journal_type_rel
account_journal_type_rel_journal_id_idx (journal_id)
is covered by
account_journal_type_rel_journal_id_type_id_key (journal_id, type_id)
On account_move_line_account_tax_rel
account_move_line_account_tax_rel_account_move_line_id_idx (account_move_line_id)
is covered by
account_move_line_account_tax_account_move_line_id_account__key (account_move_line_id, account_tax_id)
On account_report_general_ledger_journal_rel
account_report_general_ledger_journal_rel_account_id_idx (account_id)
is covered by
account_report_general_ledger_journal_account_id_journal_id_key (account_id, journal_id)
On account_tax_account_tag
account_tax_account_tag_account_tax_id_idx (account_tax_id)
is covered by
account_tax_account_tag_account_tax_id_account_account_tag__key (account_tax_id, account_account_tag_id)
On account_tax_filiation_rel
account_tax_filiation_rel_parent_tax_idx (parent_tax)
is covered by
account_tax_filiation_rel_parent_tax_child_tax_key (parent_tax, child_tax)
On account_tax_purchase_order_line_rel
account_tax_purchase_order_line_rel_purchase_order_line_id_idx (purchase_order_line_id)
is covered by
account_tax_purchase_order_li_purchase_order_line_id_accoun_key (purchase_order_line_id, account_tax_id)
On account_tax_sale_advance_payment_inv_rel
account_tax_sale_advance_paymen_sale_advance_payment_inv_id_idx (sale_advance_payment_inv_id)
is covered by
account_tax_sale_advance_paym_sale_advance_payment_inv_id_a_key (sale_advance_payment_inv_id, account_tax_id)
On account_tax_sale_order_line_rel
account_tax_sale_order_line_rel_sale_order_line_id_idx (sale_order_line_id)
is covered by
account_tax_sale_order_line_r_sale_order_line_id_account_ta_key (sale_order_line_id, account_tax_id)
On account_tax_template_filiation_rel
account_tax_template_filiation_rel_parent_tax_idx (parent_tax)
is covered by
account_tax_template_filiation_rel_parent_tax_child_tax_key (parent_tax, child_tax)
On base_partner_merge_automatic_wizard_res_partner_rel
base_partner_merge_automatic__base_partner_merge_automatic__idx (base_partner_merge_automatic_wizard_id)
is covered by
base_partner_merge_automatic__base_partner_merge_automatic__key (base_partner_merge_automatic_wizard_id, res_partner_id)
On brand_food_platform_rel
brand_food_platform_rel_platform_id_idx (platform_id)
is covered by
brand_food_platform_rel_platform_id_brand_id_key (platform_id, brand_id)
On bus_presence
bus_presence_user_id_index (user_id)
is covered by
bus_presence_bus_user_presence_unique (user_id)
On calendar_alarm_calendar_event_rel
calendar_alarm_calendar_event_rel_calendar_event_id_idx (calendar_event_id)
is covered by
calendar_alarm_calendar_event_calendar_event_id_calendar_al_key (calendar_event_id, calendar_alarm_id)
On calendar_event_res_partner_rel
calendar_event_res_partner_rel_calendar_event_id_idx (calendar_event_id)
is covered by
calendar_event_res_partner_re_calendar_event_id_res_partner_key (calendar_event_id, res_partner_id)
On change_request_attachment_rel
change_request_attachment_rel_change_request_id_idx (change_request_id)
is covered by
change_request_attachment_rel_change_request_id_attachment__key (change_request_id, attachment_id)
On combo_attribute_line_product_attribute_value_rel
combo_attribute_line_product_attrib_combo_attribute_line_id_idx (combo_attribute_line_id)
is covered by
combo_attribute_line_product__combo_attribute_line_id_produ_key (combo_attribute_line_id, product_attribute_value_id)
On crm_lead2opportunity_partner_mass_res_users_rel
crm_lead2opportunity_partner__crm_lead2opportunity_partner__idx (crm_lead2opportunity_partner_mass_id)
is covered by
crm_lead2opportunity_partner__crm_lead2opportunity_partner__key (crm_lead2opportunity_partner_mass_id, res_users_id)
On crm_lead_crm_lead2opportunity_partner_mass_rel
crm_lead_crm_lead2opportunity_crm_lead2opportunity_partner_idx1 (crm_lead2opportunity_partner_mass_id)
is covered by
crm_lead_crm_lead2opportunity_crm_lead2opportunity_partner_key1 (crm_lead2opportunity_partner_mass_id, crm_lead_id)
On crm_lead_crm_lead2opportunity_partner_rel
crm_lead_crm_lead2opportunity_crm_lead2opportunity_partner__idx (crm_lead2opportunity_partner_id)
is covered by
crm_lead_crm_lead2opportunity_crm_lead2opportunity_partner__key (crm_lead2opportunity_partner_id, crm_lead_id)
On crm_lead_tag_rel
crm_lead_tag_rel_lead_id_idx (lead_id)
is covered by
crm_lead_tag_rel_lead_id_tag_id_key (lead_id, tag_id)
On decimal_precision
decimal_precision_name_index (name)
is covered by
decimal_precision_name_uniq (name)
On delivery_order_line
delivery_order_line_order_id_index (order_id)
is covered by
delivery_order_line_kitchen_product_unique (order_id, product_id, kitchen_id)
On delivery_order_print_product_category_rel
delivery_order_print_product_catego_delivery_order_print_id_idx (delivery_order_print_id)
is covered by
delivery_order_print_product__delivery_order_print_id_produ_key (delivery_order_print_id, product_category_id)
On delivery_order_print_stock_warehouse_rel
delivery_order_print_stock_warehous_delivery_order_print_id_idx (delivery_order_print_id)
is covered by
delivery_order_print_stock_wa_delivery_order_print_id_stock_key (delivery_order_print_id, stock_warehouse_id)
On delivery_order_swk_merge_do_rel
delivery_order_swk_merge_do_rel_swk_merge_do_id_idx (swk_merge_do_id)
is covered by
delivery_order_swk_merge_do_r_swk_merge_do_id_delivery_orde_key (swk_merge_do_id, delivery_order_id)
On email_template_attachment_rel
email_template_attachment_rel_email_template_id_idx (email_template_id)
is covered by
email_template_attachment_rel_email_template_id_attachment__key (email_template_id, attachment_id)
On email_template_preview_res_partner_rel
email_template_preview_res_partne_email_template_preview_id_idx (email_template_preview_id)
is covered by
email_template_preview_res_pa_email_template_preview_id_res_key (email_template_preview_id, res_partner_id)
On food_profile_line_food_profile_tag_rel
food_profile_line_food_profile_tag_rel_food_profile_line_id_idx (food_profile_line_id)
is covered by
food_profile_line_food_profil_food_profile_line_id_food_pro_key (food_profile_line_id, food_profile_tag_id)
On helpdesk_ticket_attachment_rel
helpdesk_ticket_attachment_rel_submit_helpdesk_ticket_id_idx (submit_helpdesk_ticket_id)
is covered by
helpdesk_ticket_attachment_re_submit_helpdesk_ticket_id_att_key (submit_helpdesk_ticket_id, attachment_id)
On invoice_reconciliation_report_attachment_rel
invoice_reconciliation_report_invoice_reconciliation_report_idx (invoice_reconciliation_report_id)
is covered by
invoice_reconciliation_report_invoice_reconciliation_report_key (invoice_reconciliation_report_id, attachment_id)
On ir_act_server_mail_channel_rel
ir_act_server_mail_channel_rel_ir_act_server_id_idx (ir_act_server_id)
is covered by
ir_act_server_mail_channel_re_ir_act_server_id_mail_channel_key (ir_act_server_id, mail_channel_id)
On ir_act_server_res_partner_rel
ir_act_server_res_partner_rel_ir_act_server_id_idx (ir_act_server_id)
is covered by
ir_act_server_res_partner_rel_ir_act_server_id_res_partner__key (ir_act_server_id, res_partner_id)
On ir_act_window_group_rel
ir_act_window_group_rel_act_id_idx (act_id)
is covered by
ir_act_window_group_rel_act_id_gid_key (act_id, gid)
On ir_attachment_swk_cr_attachment_rel
ir_attachment_swk_cr_attachment_rel_swk_cr_attachment_id_idx (swk_cr_attachment_id)
is covered by
ir_attachment_swk_cr_attachme_swk_cr_attachment_id_ir_attac_key (swk_cr_attachment_id, ir_attachment_id)
On ir_config_parameter
ir_config_parameter_key_index (key)
is covered by
ir_config_parameter_key_uniq (key)
On ir_model
ir_model_model_index (model)
is covered by
ir_model_obj_name_uniq (model)
On ir_model_constraint
ir_model_constraint_name_index (name)
is covered by
ir_model_constraint_module_name_uniq (name, module)
On ir_model_fields
ir_model_fields_model_index (model)
is covered by
ir_model_fields_name_unique (model, name)
On ir_model_fields_group_rel
ir_model_fields_group_rel_field_id_idx (field_id)
is covered by
ir_model_fields_group_rel_field_id_group_id_key (field_id, group_id)
On ir_model_save_dialog
ir_model_save_dialog_model_id_index (model_id)
is covered by
ir_model_save_dialog_model_uniq (model_id)
On ir_module_module
ir_module_module_name_index (name)
is covered by
name_uniq (name)
On ir_ui_menu_group_rel
ir_ui_menu_group_rel_menu_id_idx (menu_id)
is covered by
ir_ui_menu_group_rel_menu_id_gid_key (menu_id, gid)
On ir_ui_view
ir_ui_view_model_index (model)
is covered by
ir_ui_view_model_type_inherit_id (model, inherit_id)
On ir_ui_view_custom
ir_ui_view_custom_user_id_index (user_id)
is covered by
ir_ui_view_custom_user_id_ref_id (user_id, ref_id)
On ir_ui_view_group_rel
ir_ui_view_group_rel_view_id_idx (view_id)
is covered by
ir_ui_view_group_rel_view_id_group_id_key (view_id, group_id)
On mail_activity_rel
mail_activity_rel_activity_id_idx (activity_id)
is covered by
mail_activity_rel_activity_id_recommended_id_key (activity_id, recommended_id)
On mail_channel_mail_wizard_invite_rel
mail_channel_mail_wizard_invite_rel_mail_wizard_invite_id_idx (mail_wizard_invite_id)
is covered by
mail_channel_mail_wizard_invi_mail_wizard_invite_id_mail_ch_key (mail_wizard_invite_id, mail_channel_id)
On mail_channel_res_groups_rel
mail_channel_res_groups_rel_mail_channel_id_idx (mail_channel_id)
is covered by
mail_channel_res_groups_rel_mail_channel_id_res_groups_id_key (mail_channel_id, res_groups_id)
On mail_compose_message_ir_attachments_rel
mail_compose_message_ir_attachments_rel_wizard_id_idx (wizard_id)
is covered by
mail_compose_message_ir_attachments_wizard_id_attachment_id_key (wizard_id, attachment_id)
On mail_compose_message_res_partner_rel
mail_compose_message_res_partner_rel_wizard_id_idx (wizard_id)
is covered by
mail_compose_message_res_partner_rel_wizard_id_partner_id_key (wizard_id, partner_id)
On mail_followers
mail_followers_res_model_index (res_model)
is covered by
mail_followers_mail_followers_res_channel_res_model_id_uniq (res_model, res_id, channel_id)
On mail_followers_mail_message_subtype_rel
mail_followers_mail_message_subtype_rel_mail_followers_id_idx (mail_followers_id)
is covered by
mail_followers_mail_message_s_mail_followers_id_mail_messag_key (mail_followers_id, mail_message_subtype_id)
On mail_mail_res_partner_rel
mail_mail_res_partner_rel_mail_mail_id_idx (mail_mail_id)
is covered by
mail_mail_res_partner_rel_mail_mail_id_res_partner_id_key (mail_mail_id, res_partner_id)
On mail_message
mail_message_model_index (model)
is covered by
mail_message_model_res_id_idx (model, res_id)
On mail_message_mail_channel_rel
mail_message_mail_channel_rel_mail_message_id_idx (mail_message_id)
is covered by
mail_message_mail_channel_rel_mail_message_id_mail_channel__key (mail_message_id, mail_channel_id)
On mail_message_res_partner_needaction_rel
mail_message_res_partner_needaction_rel_res_partner_id_index (res_partner_id)
is covered by
mail_notification_res_partner_id_is_read_email_status_mail_mess (res_partner_id, is_read, email_status, mail_message_id)
On mail_message_res_partner_rel
mail_message_res_partner_rel_mail_message_id_idx (mail_message_id)
is covered by
mail_message_res_partner_rel_mail_message_id_res_partner_id_key (mail_message_id, res_partner_id)
On mail_message_res_partner_starred_rel
mail_message_res_partner_starred_rel_mail_message_id_idx (mail_message_id)
is covered by
mail_message_res_partner_star_mail_message_id_res_partner_i_key (mail_message_id, res_partner_id)
On mail_wizard_invite_res_partner_rel
mail_wizard_invite_res_partner_rel_mail_wizard_invite_id_idx (mail_wizard_invite_id)
is covered by
mail_wizard_invite_res_partne_mail_wizard_invite_id_res_par_key (mail_wizard_invite_id, res_partner_id)
On meeting_category_rel
meeting_category_rel_event_id_idx (event_id)
is covered by
meeting_category_rel_event_id_type_id_key (event_id, type_id)
On merge_opportunity_rel
merge_opportunity_rel_merge_id_idx (merge_id)
is covered by
merge_opportunity_rel_merge_id_opportunity_id_key (merge_id, opportunity_id)
On message_attachment_rel
message_attachment_rel_message_id_idx (message_id)
is covered by
message_attachment_rel_message_id_attachment_id_key (message_id, attachment_id)
On mrp_bom_line_product_attribute_value_rel
mrp_bom_line_product_attribute_value_rel_mrp_bom_line_id_idx (mrp_bom_line_id)
is covered by
mrp_bom_line_product_attribut_mrp_bom_line_id_product_attri_key (mrp_bom_line_id, product_attribute_value_id)
On payment_acquirer_payment_icon_rel
payment_acquirer_payment_icon_rel_payment_acquirer_id_idx (payment_acquirer_id)
is covered by
payment_acquirer_payment_icon_payment_acquirer_id_payment_i_key (payment_acquirer_id, payment_icon_id)
On payment_country_rel
payment_country_rel_payment_id_idx (payment_id)
is covered by
payment_country_rel_payment_id_country_id_key (payment_id, country_id)
On printing_printer_swk_kitchen_config_rel
printing_printer_swk_kitchen_config_r_swk_kitchen_config_id_idx (swk_kitchen_config_id)
is covered by
printing_printer_swk_kitchen__swk_kitchen_config_id_printin_key (swk_kitchen_config_id, printing_printer_id)
On product_attribute_line_product_attribute_value_rel
product_attribute_line_product_at_product_attribute_line_id_idx (product_attribute_line_id)
is covered by
product_attribute_line_produc_product_attribute_line_id_pro_key (product_attribute_line_id, product_attribute_value_id)
On product_attribute_value_product_configurator_attribute_rel
product_attribute_value_produ_product_configurator_attribut_idx (product_configurator_attribute_id)
is covered by
product_attribute_value_produ_product_configurator_attribut_key (product_configurator_attribute_id, product_attribute_value_id)
On product_attribute_value_product_product_rel
product_attribute_value_product_product__product_product_id_idx (product_product_id)
is covered by
product_attribute_value_produ_product_product_id_product_at_key (product_product_id, product_attribute_value_id)
On product_supplier_taxes_rel
product_supplier_taxes_rel_prod_id_idx (prod_id)
is covered by
product_supplier_taxes_rel_prod_id_tax_id_key (prod_id, tax_id)
On product_taxes_rel
product_taxes_rel_prod_id_idx (prod_id)
is covered by
product_taxes_rel_prod_id_tax_id_key (prod_id, tax_id)
On purchase_order_stock_picking_rel
purchase_order_stock_picking_rel_purchase_order_id_idx (purchase_order_id)
is covered by
purchase_order_stock_picking__purchase_order_id_stock_picki_key (purchase_order_id, stock_picking_id)
On queue_job_queue_jobs_to_done_rel
queue_job_queue_jobs_to_done_rel_queue_jobs_to_done_id_idx (queue_jobs_to_done_id)
is covered by
queue_job_queue_jobs_to_done__queue_jobs_to_done_id_queue_j_key (queue_jobs_to_done_id, queue_job_id)
On queue_job_queue_requeue_job_rel
queue_job_queue_requeue_job_rel_queue_requeue_job_id_idx (queue_requeue_job_id)
is covered by
queue_job_queue_requeue_job_r_queue_requeue_job_id_queue_jo_key (queue_requeue_job_id, queue_job_id)
On rel_modules_langexport
rel_modules_langexport_wiz_id_idx (wiz_id)
is covered by
rel_modules_langexport_wiz_id_module_id_key (wiz_id, module_id)
On rel_server_actions
rel_server_actions_server_id_idx (server_id)
is covered by
rel_server_actions_server_id_action_id_key (server_id, action_id)
On res_company_swk_day_rel
res_company_swk_day_rel_res_company_id_idx (res_company_id)
is covered by
res_company_swk_day_rel_res_company_id_swk_day_id_key (res_company_id, swk_day_id)
On res_company_users_rel
res_company_users_rel_cid_idx (cid)
is covered by
res_company_users_rel_cid_user_id_key (cid, user_id)
On res_country_group_pricelist_rel
res_country_group_pricelist_rel_pricelist_id_idx (pricelist_id)
is covered by
res_country_group_pricelist_r_pricelist_id_res_country_grou_key (pricelist_id, res_country_group_id)
On res_country_res_country_group_rel
res_country_res_country_group_rel_res_country_id_idx (res_country_id)
is covered by
res_country_res_country_group_res_country_id_res_country_gr_key (res_country_id, res_country_group_id)
On res_currency_rate
res_currency_rate_name_index (name)
is covered by
res_currency_rate_unique_name_per_day (name, currency_id, company_id)
On res_groups
res_groups_category_id_index (category_id)
is covered by
res_groups_name_uniq (category_id, name)
On res_groups_implied_rel
res_groups_implied_rel_gid_idx (gid)
is covered by
res_groups_implied_rel_gid_hid_key (gid, hid)
On res_groups_report_rel
res_groups_report_rel_uid_idx (uid)
is covered by
res_groups_report_rel_uid_gid_key (uid, gid)
On res_groups_users_rel
res_groups_users_rel_gid_idx (gid)
is covered by
res_groups_users_rel_gid_uid_key (gid, uid)
On res_partner_res_partner_category_rel
res_partner_res_partner_category_rel_category_id_idx (category_id)
is covered by
res_partner_res_partner_category_rel_category_id_partner_id_key (category_id, partner_id)
On res_users_stock_warehouse_rel
res_users_stock_warehouse_rel_res_users_id_idx (res_users_id)
is covered by
res_users_stock_warehouse_rel_res_users_id_stock_warehouse__key (res_users_id, stock_warehouse_id)
On rule_group_rel
rule_group_rel_rule_group_id_idx (rule_group_id)
is covered by
rule_group_rel_rule_group_id_group_id_key (rule_group_id, group_id)
On sale_order_line_invoice_rel
sale_order_line_invoice_rel_invoice_line_id_idx (invoice_line_id)
is covered by
sale_order_line_invoice_rel_invoice_line_id_order_line_id_key (invoice_line_id, order_line_id)
On sale_order_tag_rel
sale_order_tag_rel_order_id_idx (order_id)
is covered by
sale_order_tag_rel_order_id_tag_id_key (order_id, tag_id)
On stock_location_route_categ
stock_location_route_categ_route_id_idx (route_id)
is covered by
stock_location_route_categ_route_id_categ_id_key (route_id, categ_id)
On stock_location_route_move
stock_location_route_move_move_id_idx (move_id)
is covered by
stock_location_route_move_move_id_route_id_key (move_id, route_id)
On stock_move
stock_move_product_id_index (product_id)
is covered by
stock_move_product_location2_index (product_id, location_id, location_dest_id, state)
On stock_move_line_consume_rel
stock_move_line_consume_rel_consume_line_id_idx (consume_line_id)
is covered by
stock_move_line_consume_rel_consume_line_id_produce_line_id_key (consume_line_id, produce_line_id)
On stock_move_move_rel
stock_move_move_rel_move_orig_id_idx (move_orig_id)
is covered by
stock_move_move_rel_move_orig_id_move_dest_id_key (move_orig_id, move_dest_id)
On stock_picking
stock_picking_name_index (name)
is covered by
stock_picking_name_uniq (name, company_id)
On stock_picking_backorder_rel
stock_picking_backorder_rel_stock_backorder_confirmation_id_idx (stock_backorder_confirmation_id)
is covered by
stock_picking_backorder_rel_stock_backorder_confirmation_id_key (stock_backorder_confirmation_id, stock_picking_id)
On stock_picking_transfer_rel
stock_picking_transfer_rel_stock_immediate_transfer_id_idx (stock_immediate_transfer_id)
is covered by
stock_picking_transfer_rel_stock_immediate_transfer_id_stoc_key (stock_immediate_transfer_id, stock_picking_id)
On stock_route_product
stock_route_product_route_id_idx (route_id)
is covered by
stock_route_product_route_id_product_id_key (route_id, product_id)
On stock_route_warehouse
stock_route_warehouse_route_id_idx (route_id)
is covered by
stock_route_warehouse_route_id_warehouse_id_key (route_id, warehouse_id)
On stock_warehouse
stock_warehouse_name_index (name)
is covered by
stock_warehouse_warehouse_name_uniq (name, company_id)
On stock_warehouse_swk_menu_rel
stock_warehouse_swk_menu_rel_swk_menu_id_idx (swk_menu_id)
is covered by
stock_warehouse_swk_menu_rel_swk_menu_id_stock_warehouse_id_key (swk_menu_id, stock_warehouse_id)
On stock_warehouse_talabat_menu_snooze_rel
stock_warehouse_talabat_menu_snooze__talabat_menu_snooze_id_idx (talabat_menu_snooze_id)
is covered by
stock_warehouse_talabat_menu__talabat_menu_snooze_id_stock__key (talabat_menu_snooze_id, stock_warehouse_id)
On stock_wh_resupply_table
stock_wh_resupply_table_supplied_wh_id_idx (supplied_wh_id)
is covered by
stock_wh_resupply_table_supplied_wh_id_supplier_wh_id_key (supplied_wh_id, supplier_wh_id)
On swk_brand_hours_swk_day_rel
swk_brand_hours_swk_day_rel_swk_brand_hours_id_idx (swk_brand_hours_id)
is covered by
swk_brand_hours_swk_day_rel_swk_brand_hours_id_swk_day_id_key (swk_brand_hours_id, swk_day_id)
On swk_brand_swk_day_rel
swk_brand_swk_day_rel_swk_brand_id_idx (swk_brand_id)
is covered by
swk_brand_swk_day_rel_swk_brand_id_swk_day_id_key (swk_brand_id, swk_day_id)
On swk_brand_swk_menu_item_rel
swk_brand_swk_menu_item_rel_swk_brand_id_idx (swk_brand_id)
is covered by
swk_brand_swk_menu_item_rel_swk_brand_id_swk_menu_item_id_key (swk_brand_id, swk_menu_item_id)
On swk_menu_item_talabat_menu_snooze_rel
swk_menu_item_talabat_menu_snooze_re_talabat_menu_snooze_id_idx (talabat_menu_snooze_id)
is covered by
swk_menu_item_talabat_menu_sn_talabat_menu_snooze_id_swk_me_key (talabat_menu_snooze_id, swk_menu_item_id)
On swk_menu_item_upload_menu_item_rel
swk_menu_item_upload_menu_item_rel_upload_menu_item_id_idx (upload_menu_item_id)
is covered by
swk_menu_item_upload_menu_ite_upload_menu_item_id_swk_menu__key (upload_menu_item_id, swk_menu_item_id)
On swk_menu_swk_menu_item_rel
swk_menu_swk_menu_item_rel_swk_menu_id_idx (swk_menu_id)
is covered by
swk_menu_swk_menu_item_rel_swk_menu_id_swk_menu_item_id_key (swk_menu_id, swk_menu_item_id)
On swk_merge_pt_swk_production_ticket_rel
swk_merge_pt_swk_production_ticket_rel_swk_merge_pt_id_idx (swk_merge_pt_id)
is covered by
swk_merge_pt_swk_production_t_swk_merge_pt_id_swk_productio_key (swk_merge_pt_id, swk_production_ticket_id)
On team_favorite_user_rel
team_favorite_user_rel_team_id_idx (team_id)
is covered by
team_favorite_user_rel_team_id_user_id_key (team_id, user_id)
On zomato_recommended
zomato_recommended_menu_id_idx (menu_id)
is covered by
zomato_recommended_menu_id_item_id_key (menu_id, item_id)

Suggested Indexes

Add indexes to speed up queries.

rails generate migration add_suggested_indexes

And paste

commit_db_transaction
add_index :ir_attachment, "url gist_trgm_ops", using: "gist", algorithm: :concurrently

add_index :mrp_production, [:product_id, :date_planned_start], algorithm: :concurrently
add_index :order_dispatch, [:create_date], algorithm: :concurrently
add_index :product_price_history, [:product_id, :datetime], algorithm: :concurrently
add_index :swk_suborder, [:so_line_id], algorithm: :concurrently

Details
CREATE INDEX CONCURRENTLY ON ir_attachment USING gist (url gist_trgm_ops)
Rows: 1259653
Row progression: 1259653, 17

Row estimates
- url (~~): 17
- create_uid (=): 314913
- datas_fname (sort): 1

Existing indexes
- id PRIMARY
- checksum
- res_model, res_id
- url

to speed up

Total Time Average Time Calls
836 min 31% 606 ms 82,790 odoo
SELECT max(id)
               FROM ir_attachment
              WHERE create_uid = $1
                AND url like $2
           GROUP BY datas_fname
           ORDER BY datas_fname

Details
CREATE INDEX CONCURRENTLY ON mrp_production (product_id, date_planned_start)
Rows: 1099308
Row progression: 1099308, 62, 0

Row estimates
- product_id (=): 62
- date_planned_start (sort): 1
- id (sort): 1

Existing indexes
- id PRIMARY
- date_finished
- date_planned_finished
- date_planned_start
- date_start
- name, company_id UNIQUE

to speed up

Total Time Average Time Calls
40 min 2% 463 ms 5,191 odoo
SELECT "mrp_production".id FROM "mrp_production" WHERE ("mrp_production"."product_id" in ($1)) ORDER BY "mrp_production"."date_planned_start" ASC,"mrp_production"."id"

Details
CREATE INDEX CONCURRENTLY ON order_dispatch (create_date)
Rows: 504490
Row progression: 504490, 50449

Row estimates
- create_date (>=): 50449
- create_date (<=): 50449
- state (sort): 252245

Existing indexes
- id PRIMARY
- edd
- retry
- state
- sync_id

to speed up

Total Time Average Time Calls
3 min 0.1% 1,254 ms 132 odoo
SELECT min("order_dispatch".id) AS id, count("order_dispatch".id) AS "__count" , "order_dispatch"."state" as "state" 
            FROM "order_dispatch"
            WHERE (("order_dispatch"."create_date" >= $1)  AND  ("order_dispatch"."create_date" <= $2))
            GROUP BY "order_dispatch"."state"
            ORDER BY "state"
3 min 0.1% 1,252 ms 132 odoo
SELECT min("order_dispatch".id) AS id, count("order_dispatch".id) AS "__count" 
            FROM "order_dispatch"
            WHERE (("order_dispatch"."create_date" >= $1)  AND  ("order_dispatch"."create_date" <= $2))

Details
CREATE INDEX CONCURRENTLY ON product_price_history (product_id, datetime)
Rows: 11412050
Row progression: 11412050, 6185, 619

Row estimates
- product_id (=): 6185
- datetime (<): 1141206
- company_id (=): 11412050
- datetime (sort): 6

Existing indexes
- id PRIMARY

to speed up

Total Time Average Time Calls
487 min 18% 2,815 ms 10,379 odoo
SELECT "product_price_history".id FROM "product_price_history" WHERE ((("product_price_history"."company_id" = $1)  AND  ("product_price_history"."product_id" = $2))  AND  ("product_price_history"."datetime" < $3)) ORDER BY "product_price_history"."datetime" DESC,"product_price_history"."id" DESC  limit $4

Details
CREATE INDEX CONCURRENTLY ON swk_suborder (so_line_id)
Rows: 1102512
Row progression: 1102512, 1

Row estimates
- so_line_id (=): 1
- id (sort): 1

Existing indexes
- id PRIMARY
- brand_id
- date
- kitchen_id
- manufacturing_order
- name
- order_partner_id
- picking_id
- platform_id
- so_id
- state

to speed up

Total Time Average Time Calls
455 min 17% 521 ms 52,415 odoo
SELECT "swk_suborder".id FROM "swk_suborder" WHERE ("swk_suborder"."so_line_id" in ($1)) ORDER BY "swk_suborder"."id"
195 min 7% 571 ms 20,438 odoo
SELECT "swk_suborder".id FROM "swk_suborder" WHERE ("swk_suborder"."so_line_id" in ($1,$2)) ORDER BY "swk_suborder"."id"
74 min 3% 574 ms 7,761 odoo
SELECT "swk_suborder".id FROM "swk_suborder" WHERE ("swk_suborder"."so_line_id" in ($1,$2,$3)) ORDER BY "swk_suborder"."id"
30 min 1% 566 ms 3,132 odoo
SELECT "swk_suborder".id FROM "swk_suborder" WHERE ("swk_suborder"."so_line_id" in ($1,$2,$3,$4)) ORDER BY "swk_suborder"."id"
12 min 0.5% 566 ms 1,287 odoo
SELECT "swk_suborder".id FROM "swk_suborder" WHERE ("swk_suborder"."so_line_id" in ($1,$2,$3,$4,$5)) ORDER BY "swk_suborder"."id"
6 min 0.2% 615 ms 598 odoo
SELECT "swk_suborder".id FROM "swk_suborder" WHERE ("swk_suborder"."so_line_id" in ($1,$2,$3,$4,$5,$6)) ORDER BY "swk_suborder"."id"
3 min 0.1% 604 ms 291 odoo
SELECT "swk_suborder".id FROM "swk_suborder" WHERE ("swk_suborder"."so_line_id" in ($1,$2,$3,$4,$5,$6,$7)) ORDER BY "swk_suborder"."id"
1 min < 0.1% 610 ms 103 odoo
SELECT "swk_suborder".id FROM "swk_suborder" WHERE ("swk_suborder"."so_line_id" in ($1,$2,$3,$4,$5,$6,$7,$8)) ORDER BY "swk_suborder"."id"
1 min < 0.1% 659 ms 53 odoo
SELECT "swk_suborder".id FROM "swk_suborder" WHERE ("swk_suborder"."so_line_id" in ($1,$2,$3,$4,$5,$6,$7,$8,$9)) ORDER BY "swk_suborder"."id"

Slow Queries

Slow queries take 20 ms or more on average and have been called at least 100 times.

Explain queries to see where to add indexes.

Total Time Average Time Calls
836 min 31% 606 ms 82,790 odoo
SELECT max(id)
               FROM ir_attachment
              WHERE create_uid = $1
                AND url like $2
           GROUP BY datas_fname
           ORDER BY datas_fname
Details
CREATE INDEX CONCURRENTLY ON ir_attachment USING gist (url gist_trgm_ops)
Rows: 1259653
Row progression: 1259653, 17

Row estimates
- url (~~): 17
- create_uid (=): 314913
- datas_fname (sort): 1

Existing indexes
- id PRIMARY
- checksum
- res_model, res_id
- url
487 min 18% 2,815 ms 10,379 odoo
SELECT "product_price_history".id FROM "product_price_history" WHERE ((("product_price_history"."company_id" = $1)  AND  ("product_price_history"."product_id" = $2))  AND  ("product_price_history"."datetime" < $3)) ORDER BY "product_price_history"."datetime" DESC,"product_price_history"."id" DESC  limit $4
Details
CREATE INDEX CONCURRENTLY ON product_price_history (product_id, datetime)
Rows: 11412050
Row progression: 11412050, 6185, 619

Row estimates
- product_id (=): 6185
- datetime (<): 1141206
- company_id (=): 11412050
- datetime (sort): 6

Existing indexes
- id PRIMARY
455 min 17% 521 ms 52,415 odoo
SELECT "swk_suborder".id FROM "swk_suborder" WHERE ("swk_suborder"."so_line_id" in ($1)) ORDER BY "swk_suborder"."id"
Details
CREATE INDEX CONCURRENTLY ON swk_suborder (so_line_id)
Rows: 1102512
Row progression: 1102512, 1

Row estimates
- so_line_id (=): 1
- id (sort): 1

Existing indexes
- id PRIMARY
- brand_id
- date
- kitchen_id
- manufacturing_order
- name
- order_partner_id
- picking_id
- platform_id
- so_id
- state
195 min 7% 571 ms 20,438 odoo
SELECT "swk_suborder".id FROM "swk_suborder" WHERE ("swk_suborder"."so_line_id" in ($1,$2)) ORDER BY "swk_suborder"."id"
Details
CREATE INDEX CONCURRENTLY ON swk_suborder (so_line_id)
Rows: 1102512
Row progression: 1102512, 1

Row estimates
- so_line_id (=): 1
- id (sort): 1

Existing indexes
- id PRIMARY
- brand_id
- date
- kitchen_id
- manufacturing_order
- name
- order_partner_id
- picking_id
- platform_id
- so_id
- state
74 min 3% 574 ms 7,761 odoo
SELECT "swk_suborder".id FROM "swk_suborder" WHERE ("swk_suborder"."so_line_id" in ($1,$2,$3)) ORDER BY "swk_suborder"."id"
Details
CREATE INDEX CONCURRENTLY ON swk_suborder (so_line_id)
Rows: 1102512
Row progression: 1102512, 1

Row estimates
- so_line_id (=): 1
- id (sort): 1

Existing indexes
- id PRIMARY
- brand_id
- date
- kitchen_id
- manufacturing_order
- name
- order_partner_id
- picking_id
- platform_id
- so_id
- state
40 min 2% 463 ms 5,191 odoo
SELECT "mrp_production".id FROM "mrp_production" WHERE ("mrp_production"."product_id" in ($1)) ORDER BY "mrp_production"."date_planned_start" ASC,"mrp_production"."id"
Details
CREATE INDEX CONCURRENTLY ON mrp_production (product_id, date_planned_start)
Rows: 1099308
Row progression: 1099308, 62, 0

Row estimates
- product_id (=): 62
- date_planned_start (sort): 1
- id (sort): 1

Existing indexes
- id PRIMARY
- date_finished
- date_planned_finished
- date_planned_start
- date_start
- name, company_id UNIQUE
30 min 1% 566 ms 3,132 odoo
SELECT "swk_suborder".id FROM "swk_suborder" WHERE ("swk_suborder"."so_line_id" in ($1,$2,$3,$4)) ORDER BY "swk_suborder"."id"
Details
CREATE INDEX CONCURRENTLY ON swk_suborder (so_line_id)
Rows: 1102512
Row progression: 1102512, 1

Row estimates
- so_line_id (=): 1
- id (sort): 1

Existing indexes
- id PRIMARY
- brand_id
- date
- kitchen_id
- manufacturing_order
- name
- order_partner_id
- picking_id
- platform_id
- so_id
- state
26 min 1.0% 13,000 ms 120 odoo
SELECT res_partner.id
                         FROM "res_partner"
                       WHERE (("res_partner"."type" != $1)  OR  "res_partner"."type" IS NULL ) AND  (res_partner.email ilike $2
                           OR res_partner.display_name ilike $3
                           OR res_partner.ref ilike $4
                           OR res_partner.vat ilike $5)
                           -- don't panic, trust postgres bitmap
                     ORDER BY res_partner.display_name ilike $6 desc,
                              res_partner.display_name
24 min 0.9% 2,116 ms 691 odoo
SELECT count($1) FROM "sale_order" WHERE (("sale_order"."warehouse_id" = $2)  AND  (("sale_order"."fo_state" not in ($3,$4,$5)) OR "sale_order"."fo_state" IS NULL)) AND (("sale_order"."company_id" IS NULL   OR  ("sale_order"."company_id" in ($6)))  AND  (("sale_order"."warehouse_id" in ($7,$8,$9,$10,$11,$12,$13,$14,$15,$16,$17))  OR  ("sale_order"."warehouse_id" in ($18,$19,$20,$21,$22,$23,$24,$25,$26,$27,$28))))
18 min 0.7% 5,847 ms 181 odoo
SELECT res_partner.id
                         FROM "res_partner"
                       WHERE ("res_partner"."active" = $1) AND (("res_partner"."type" != $2)  OR  "res_partner"."type" IS NULL ) AND  (res_partner.email ilike $3
                           OR res_partner.display_name ilike $4
                           OR res_partner.ref ilike $5
                           OR res_partner.vat ilike $6)
                           -- don't panic, trust postgres bitmap
                     ORDER BY res_partner.display_name ilike $7 desc,
                              res_partner.display_name
16 min 0.6% 4,261 ms 223 odoo
SELECT COUNT(DISTINCT partner_id) 
                FROM sale_order
                WHERE is_food_order = $1 AND employee_meal = $2 AND state = $3 AND date_order >= $4 AND date_order <= $5 AND warehouse_id = $6 AND
                partner_id NOT IN (SELECT DISTINCT partner_id FROM sale_order WHERE is_food_order = $7 AND date_order < $8 AND warehouse_id = $9)
12 min 0.5% 1,259 ms 592 odoo
SELECT count($1) FROM "sale_order" WHERE (("sale_order"."fo_state" not in ($2,$3,$4)) OR "sale_order"."fo_state" IS NULL) AND (("sale_order"."company_id" IS NULL   OR  ("sale_order"."company_id" in ($5)))  AND  (("sale_order"."warehouse_id" in ($6))  OR  ("sale_order"."warehouse_id" in ($7))))
12 min 0.5% 566 ms 1,287 odoo
SELECT "swk_suborder".id FROM "swk_suborder" WHERE ("swk_suborder"."so_line_id" in ($1,$2,$3,$4,$5)) ORDER BY "swk_suborder"."id"
Details
CREATE INDEX CONCURRENTLY ON swk_suborder (so_line_id)
Rows: 1102512
Row progression: 1102512, 1

Row estimates
- so_line_id (=): 1
- id (sort): 1

Existing indexes
- id PRIMARY
- brand_id
- date
- kitchen_id
- manufacturing_order
- name
- order_partner_id
- picking_id
- platform_id
- so_id
- state
8 min 0.3% 702 ms 688 odoo
SELECT "sale_order".id FROM "sale_order" WHERE (("sale_order"."warehouse_id" = $1)  AND  (("sale_order"."fo_state" not in ($2,$3,$4)) OR "sale_order"."fo_state" IS NULL)) AND (("sale_order"."company_id" IS NULL   OR  ("sale_order"."company_id" in ($5)))  AND  (("sale_order"."warehouse_id" in ($6,$7,$8,$9,$10,$11,$12,$13,$14,$15,$16))  OR  ("sale_order"."warehouse_id" in ($17,$18,$19,$20,$21,$22,$23,$24,$25,$26,$27)))) ORDER BY "sale_order"."date_order" DESC,"sale_order"."id" DESC  limit $28
6 min 0.2% 615 ms 598 odoo
SELECT "swk_suborder".id FROM "swk_suborder" WHERE ("swk_suborder"."so_line_id" in ($1,$2,$3,$4,$5,$6)) ORDER BY "swk_suborder"."id"
Details
CREATE INDEX CONCURRENTLY ON swk_suborder (so_line_id)
Rows: 1102512
Row progression: 1102512, 1

Row estimates
- so_line_id (=): 1
- id (sort): 1

Existing indexes
- id PRIMARY
- brand_id
- date
- kitchen_id
- manufacturing_order
- name
- order_partner_id
- picking_id
- platform_id
- so_id
- state
5 min 0.2% 2,029 ms 160 odoo
SELECT count($1) FROM "sale_order" WHERE (("sale_order"."fo_state" not in ($2,$3,$4)) OR "sale_order"."fo_state" IS NULL) AND (("sale_order"."company_id" IS NULL   OR  ("sale_order"."company_id" in ($5)))  AND  (("sale_order"."warehouse_id" in ($6,$7,$8,$9,$10,$11,$12,$13,$14,$15,$16))  OR  ("sale_order"."warehouse_id" in ($17,$18,$19,$20,$21,$22,$23,$24,$25,$26,$27))))
4 min 0.2% 1,149 ms 223 odoo
SELECT COUNT(DISTINCT so.partner_id) 
                FROM sale_order so
                WHERE so.is_food_order = $1 AND employee_meal = $2 AND so.state = $3 AND so.date_order >= $4 AND so.date_order <= $5 AND warehouse_id = $6 
                AND so.partner_id IN (SELECT DISTINCT so2.partner_id 
                                      FROM sale_order so2 
                                      WHERE so2.is_food_order = $7
                                      AND so2.date_order < $8 AND warehouse_id = $9)
                AND so.brand_id NOT IN (SELECT DISTINCT so3.brand_id 
                                        FROM sale_order so3 
                                        WHERE so3.is_food_order
                                        AND so3.partner_id = so.partner_id
                                        AND so3.date_order < $10 AND warehouse_id = $11
                                        AND so.brand_id = so3.brand_id)
4 min 0.2% 1,111 ms 223 odoo
SELECT COUNT(DISTINCT partner_id) 
                FROM sale_order
                WHERE is_food_order = $1 AND employee_meal = $2 AND state = $3 AND date_order >= $4 AND date_order <= $5 AND warehouse_id = $6
                AND partner_id IN (SELECT DISTINCT partner_id FROM sale_order WHERE is_food_order = $7 AND date_order < $8 AND warehouse_id = $9)
4 min 0.1% 1,364 ms 171 odoo
SELECT count($1) FROM "sale_order" WHERE (((("sale_order"."state" in ($2,$3))  AND  ("sale_order"."employee_meal" IS NULL or "sale_order"."employee_meal" = $4 ))  AND  ("sale_order"."warehouse_id" = $5))  AND  ("sale_order"."is_food_order" = $6)) AND (("sale_order"."company_id" IS NULL   OR  ("sale_order"."company_id" in ($7)))  AND  (("sale_order"."warehouse_id" in ($8,$9,$10,$11,$12,$13,$14,$15,$16,$17,$18,$19,$20,$21,$22,$23,$24))  OR  ("sale_order"."warehouse_id" in ($25,$26,$27,$28,$29,$30,$31,$32,$33,$34,$35,$36,$37,$38,$39,$40,$41))))
3 min 0.1% 604 ms 291 odoo
SELECT "swk_suborder".id FROM "swk_suborder" WHERE ("swk_suborder"."so_line_id" in ($1,$2,$3,$4,$5,$6,$7)) ORDER BY "swk_suborder"."id"
Details
CREATE INDEX CONCURRENTLY ON swk_suborder (so_line_id)
Rows: 1102512
Row progression: 1102512, 1

Row estimates
- so_line_id (=): 1
- id (sort): 1

Existing indexes
- id PRIMARY
- brand_id
- date
- kitchen_id
- manufacturing_order
- name
- order_partner_id
- picking_id
- platform_id
- so_id
- state
3 min 0.1% 1,263 ms 132 odoo
SELECT min("order_dispatch".id) AS id, count("order_dispatch".id) AS "__count" , "order_dispatch"."warehouse_id" as "warehouse_id" 
            FROM "order_dispatch" LEFT JOIN "stock_warehouse" as "order_dispatch__warehouse_id" ON ("order_dispatch"."warehouse_id" = "order_dispatch__warehouse_id"."id")
            WHERE (("order_dispatch"."create_date" >= $1)  AND  ("order_dispatch"."create_date" <= $2))
            GROUP BY "order_dispatch"."warehouse_id","order_dispatch__warehouse_id"."name"
            ORDER BY  "order_dispatch__warehouse_id"."name"
3 min 0.1% 1,254 ms 132 odoo
SELECT min("order_dispatch".id) AS id, count("order_dispatch".id) AS "__count" , "order_dispatch"."state" as "state" 
            FROM "order_dispatch"
            WHERE (("order_dispatch"."create_date" >= $1)  AND  ("order_dispatch"."create_date" <= $2))
            GROUP BY "order_dispatch"."state"
            ORDER BY "state"
Details
CREATE INDEX CONCURRENTLY ON order_dispatch (create_date)
Rows: 504490
Row progression: 504490, 50449

Row estimates
- create_date (>=): 50449
- create_date (<=): 50449
- state (sort): 252245

Existing indexes
- id PRIMARY
- edd
- retry
- state
- sync_id
3 min 0.1% 1,252 ms 132 odoo
SELECT min("order_dispatch".id) AS id, count("order_dispatch".id) AS "__count" 
            FROM "order_dispatch"
            WHERE (("order_dispatch"."create_date" >= $1)  AND  ("order_dispatch"."create_date" <= $2))
Details
CREATE INDEX CONCURRENTLY ON order_dispatch (create_date)
Rows: 504490
Row progression: 504490, 50449

Row estimates
- create_date (>=): 50449
- create_date (<=): 50449

Existing indexes
- id PRIMARY
- edd
- retry
- state
- sync_id
3 min < 0.1% 612 ms 260 odoo
SELECT count($1) FROM "sale_order" WHERE (((("sale_order"."state" in ($2,$3))  AND  ("sale_order"."employee_meal" IS NULL or "sale_order"."employee_meal" = $4 ))  AND  ("sale_order"."warehouse_id" = $5))  AND  ("sale_order"."is_food_order" = $6)) AND (("sale_order"."company_id" IS NULL   OR  ("sale_order"."company_id" in ($7)))  AND  (("sale_order"."warehouse_id" in ($8,$9,$10,$11,$12,$13,$14,$15,$16,$17,$18))  OR  ("sale_order"."warehouse_id" in ($19,$20,$21,$22,$23,$24,$25,$26,$27,$28,$29))))
2 min < 0.1% 887 ms 167 odoo
SELECT "swk_suborder".id FROM "swk_suborder" WHERE ("swk_suborder"."so_line_id" in ($1)) AND (("swk_suborder"."kitchen_id" in ($2))  OR  ("swk_suborder"."kitchen_id" in ($3))) ORDER BY "swk_suborder"."id" DESC
2 min < 0.1% 865 ms 160 odoo
SELECT "swk_suborder".id FROM "swk_suborder" WHERE ("swk_suborder"."so_line_id" in ($1,$2)) AND (("swk_suborder"."kitchen_id" in ($3))  OR  ("swk_suborder"."kitchen_id" in ($4))) ORDER BY "swk_suborder"."id" DESC
2 min < 0.1% 230 ms 551 odoo
SELECT count($1) FROM "sale_order" WHERE (((("sale_order"."state" in ($2,$3))  AND  ("sale_order"."employee_meal" IS NULL or "sale_order"."employee_meal" = $4 ))  AND  ("sale_order"."warehouse_id" = $5))  AND  ("sale_order"."is_food_order" = $6)) AND (("sale_order"."company_id" IS NULL   OR  ("sale_order"."company_id" in ($7)))  AND  (("sale_order"."warehouse_id" in ($8))  OR  ("sale_order"."warehouse_id" in ($9))))
2 min < 0.1% 941 ms 132 odoo
SELECT min("order_dispatch".id) AS id, count("order_dispatch".id) AS "__count" , "order_dispatch"."warehouse_id" as "warehouse_id" ,"order_dispatch"."state" as "state" 
            FROM "order_dispatch" LEFT JOIN "stock_warehouse" as "order_dispatch__warehouse_id" ON ("order_dispatch"."warehouse_id" = "order_dispatch__warehouse_id"."id")
            WHERE (("order_dispatch"."create_date" >= $1)  AND  ("order_dispatch"."create_date" <= $2))
            GROUP BY "order_dispatch"."warehouse_id","order_dispatch"."state","order_dispatch__warehouse_id"."name"
            ORDER BY  "order_dispatch__warehouse_id"."name"  ,"state"
2 min < 0.1% 929 ms 100 odoo
SELECT count($1) FROM "swk_suborder" WHERE ("swk_suborder"."state" in ($2,$3)) AND (("swk_suborder"."kitchen_id" in ($4))  OR  ("swk_suborder"."kitchen_id" in ($5)))
1 min < 0.1% 610 ms 103 odoo
SELECT "swk_suborder".id FROM "swk_suborder" WHERE ("swk_suborder"."so_line_id" in ($1,$2,$3,$4,$5,$6,$7,$8)) ORDER BY "swk_suborder"."id"
Details
CREATE INDEX CONCURRENTLY ON swk_suborder (so_line_id)
Rows: 1102512
Row progression: 1102512, 1

Row estimates
- so_line_id (=): 1
- id (sort): 1

Existing indexes
- id PRIMARY
- brand_id
- date
- kitchen_id
- manufacturing_order
- name
- order_partner_id
- picking_id
- platform_id
- so_id
- state
1 min < 0.1% 85 ms 571 odoo
SELECT "product_product".id FROM "product_product" WHERE (((((((("product_product"."product_tmpl_id" = $1)  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($2))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($3))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($4))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($5))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($6))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($7))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($8)))) ORDER BY "product_product"."default_code" ,"product_product"."id"
1 min < 0.1% 75 ms 633 odoo
SELECT "product_product".id FROM "product_product" WHERE (((((("product_product"."product_tmpl_id" = $1)  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($2))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($3))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($4))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($5))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($6)))) ORDER BY "product_product"."default_code" ,"product_product"."id"
1 min < 0.1% 131 ms 319 odoo
SELECT "product_product".id FROM "product_product" WHERE ((((((((("product_product"."product_tmpl_id" = $1)  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($2))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($3))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($4))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($5))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($6))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($7))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($8))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($9)))) ORDER BY "product_product"."default_code" ,"product_product"."id"
1 min < 0.1% 78 ms 534 odoo
SELECT "product_product".id FROM "product_product" WHERE ((((((("product_product"."product_tmpl_id" = $1)  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($2))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($3))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($4))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($5))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($6))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($7)))) ORDER BY "product_product"."default_code" ,"product_product"."id"
1 min < 0.1% 113 ms 367 odoo
SELECT "product_product".id FROM "product_product" WHERE (((((((((("product_product"."product_tmpl_id" = $1)  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($2))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($3))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($4))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($5))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($6))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($7))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($8))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($9))))  AND  ("product_product"."id" in (SELECT "product_product_id" FROM "product_attribute_value_product_product_rel" WHERE "product_attribute_value_id" IN ($10)))) ORDER BY "product_product"."default_code" ,"product_product"."id"
1 min < 0.1% 104 ms 370 odoo
SELECT min("sale_report".id) AS id, count("sale_report".id) AS "__count" , sum("sale_report"."price_subtotal") AS "price_subtotal" 
            FROM "sale_report"
            WHERE (("sale_report"."date" <= $1)  AND  ("sale_report"."date" >= $2)) AND ("sale_report"."company_id" IS NULL   OR  ("sale_report"."company_id" in ($3)))
1 min < 0.1% 352 ms 107 odoo
SELECT schemaname AS schema, t.relname AS table, ix.relname AS name, regexp_replace(pg_get_indexdef(i.indexrelid), $1, $2) AS columns, regexp_replace(pg_get_indexdef(i.indexrelid), $3, $4) AS using, indisunique AS unique, indisprimary AS primary, indisvalid AS valid, indexprs::text, indpred::text, pg_get_indexdef(i.indexrelid) AS definition FROM pg_index i INNER JOIN pg_class t ON t.oid = i.indrelid INNER JOIN pg_class ix ON ix.oid = i.indexrelid LEFT JOIN pg_stat_user_indexes ui ON ui.indexrelid = i.indexrelid WHERE schemaname IS NOT NULL ORDER BY 1, 2 /*pghero*/
1 min < 0.1% 102 ms 370 odoo
SELECT min("sale_report".id) AS id, count("sale_report".id) AS "__count" , sum("sale_report"."price_subtotal") AS "price_subtotal" ,"sale_report"."team_id" as "team_id" 
            FROM "sale_report" LEFT JOIN "crm_team" as "sale_report__team_id" ON ("sale_report"."team_id" = "sale_report__team_id"."id") LEFT JOIN 
                (SELECT DISTINCT ON (res_id) res_id, value
                 FROM "ir_translation"
                 WHERE name=$1 AND lang=$2 AND value!=$3
                 ORDER BY res_id, id DESC)
             as "sale_report__team_id__name" ON ("sale_report__team_id"."id" = "sale_report__team_id__name"."res_id")
            WHERE (("sale_report"."date" <= $4)  AND  ("sale_report"."date" >= $5)) AND ("sale_report"."company_id" IS NULL   OR  ("sale_report"."company_id" in ($6)))
            GROUP BY "sale_report"."team_id",COALESCE("sale_report__team_id__name"."value","sale_report__team_id"."name")
            ORDER BY  COALESCE("sale_report__team_id__name"."value", "sale_report__team_id"."name")
1 min < 0.1% 345 ms 106 odoo
WITH query_stats AS ( SELECT LEFT(query, $1) AS query, queryid AS query_hash, rolname AS user, ((total_plan_time + total_exec_time) / $2 / $3) AS total_minutes, ((total_plan_time + total_exec_time) / calls) AS average_time, calls FROM pg_stat_statements INNER JOIN pg_database ON pg_database.oid = pg_stat_statements.dbid INNER JOIN pg_roles ON pg_roles.oid = pg_stat_statements.userid WHERE calls > $4 AND pg_database.datname = current_database() ) SELECT query, query AS explainable_query, query_hash, query_stats.user, total_minutes, average_time, calls, total_minutes * $5 / (SELECT SUM(total_minutes) FROM query_stats) AS total_percent, (SELECT SUM(total_minutes) FROM query_stats) AS all_queries_total_minutes FROM query_stats ORDER BY "total_minutes" DESC LIMIT $6 /*pghero*/
1 min < 0.1% 93 ms 370 odoo
SELECT min("sale_report".id) AS id, count("sale_report".id) AS "__count" , sum("sale_report"."price_subtotal") AS "price_subtotal" ,"sale_report"."warehouse_id" as "warehouse_id" 
            FROM "sale_report" LEFT JOIN "stock_warehouse" as "sale_report__warehouse_id" ON ("sale_report"."warehouse_id" = "sale_report__warehouse_id"."id")
            WHERE (("sale_report"."date" <= $1)  AND  ("sale_report"."date" >= $2)) AND ("sale_report"."company_id" IS NULL   OR  ("sale_report"."company_id" in ($3)))
            GROUP BY "sale_report"."warehouse_id","sale_report__warehouse_id"."name"
            ORDER BY  "sale_report__warehouse_id"."name"