public inbox for [email protected]  
help / color / mirror / Atom feed
From: Greg Sabino Mullane <[email protected]>
To: Durgamahesh Manne <[email protected]>
Cc: PostgreSQL mailing lists <[email protected]>
Subject: Re: Inefficient use of index scan on 2nd column of composite index during concurrent activity
Date: Fri, 11 Oct 2024 12:26:40 -0400
Message-ID: <CAKAnmmJsqAPNbN8GKzJURwqTNAi+vTQVe2TbvE+BY0t=4K8ARQ@mail.gmail.com> (raw)
In-Reply-To: <CAJCZkoKEA4ZcYq0ereB2vFUQ+RQ8o2CEAUu5a4p-_ijuUvFL0g@mail.gmail.com>
References: <CAJCZkoL3E5M7taGpdtJRhwM0zCQ1-T2uzv4FKj_Arrz-fRusOQ@mail.gmail.com>
	<CAJCZkoKEA4ZcYq0ereB2vFUQ+RQ8o2CEAUu5a4p-_ijuUvFL0g@mail.gmail.com>

On Fri, Oct 11, 2024 at 9:28 AM Durgamahesh Manne <[email protected]>
wrote:

> composite key (placedon,id)
> In concurrent mode if i use id at where clause then query plan for that id
> column changes
>
> How to mitigate it rather than use seperate index for id to continue
> without change in query plan (index scan) during concurrent activity
>

Why the focus on "concurrent mode"? Perhaps explain what you mean by that.

Speaking of explain, it might help if you show us the explain plans and how
they are not coming out how you want. Also the table definitions, but feel
free to not show columns unrelated to the problem.

Cheers,
Greg


view thread (2+ messages)

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: [email protected]
  Cc: [email protected], [email protected]
  Subject: Re: Inefficient use of index scan on 2nd column of composite index during concurrent activity
  In-Reply-To: <CAKAnmmJsqAPNbN8GKzJURwqTNAi+vTQVe2TbvE+BY0t=4K8ARQ@mail.gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox