public inbox for [email protected]  
help / color / mirror / Atom feed
From: Durgamahesh Manne <[email protected]>
To: Rob Sargent <[email protected]>
Cc: Adrian Klaver <[email protected]>
Cc: pgsql-general <[email protected]>
Cc: [email protected]
Subject: Re: Query optimization
Date: Fri, 14 Mar 2025 08:09:46 +0530
Message-ID: <CAJCZko+jAv98MZJp0T8KthDoWKdmhKTk-XukQJ1CR-v=+mSRhg@mail.gmail.com> (raw)
In-Reply-To: <[email protected]>
References: <CAJCZkoL+DHs0H9enQEg8JXZw=7032zrmFKG8Vx0fup6_wqNpnQ@mail.gmail.com>
	<[email protected]>
	<CAJCZkoLSaApgwHuWepO4EUENtjKMy1oX+GpEsFW4D+gFKoN_GQ@mail.gmail.com>
	<[email protected]>

On Fri, 14 Mar, 2025, 08:04 Rob Sargent, <[email protected]> wrote:

>
>
>
> 3) Output of EXPLAIN ANALYZE of query.
>
>  Result  (cost=2.80..2.83 rows=1 width=1) (actual time=0.030..0.030 rows=1
> loops=1)
>    InitPlan 1 (returns $0)
>      ->  Index Only Scan using idx_cachekeys on cachekeys
>  (cost=0.55..2.80 rows=1 width=0) (actual time=0.029..0.029 rows=1 loops=1)
>            Index Cond: ((cachetype = 'BoMatrix'::text) AND (trsid =
> 'daznbetuk'::text) AND (brandid = 'daznbet'::text) AND (sportid =
> 'BOX'::text) AND (competitionid = 'U-1998'::text) AND (eventid =
> 'U-523596'::text))
>            Heap Fetches: 0
>  Planning Time: 0.221 ms
>  Execution Time: 0.046 ms
>
>
>
> And is the explain analyze output if from your original query:
> "SELECT EXISTS (SELECT Key FROM CACHEKEYS WHERE CacheType = $1 AND TrsId
> = $2 AND BrandId = $3 AND SportId = $4 AND CompetitionId = $5 AND EventId =
> $6 AND MarketId = $7 LIMIT ?)”
>
> Has there been any significant addition of rows recently? i.e. are the
> statistics up-to-date for that table?
>
Hi

Gave you plan with out limit . Stats up to date insert .....on conflict do
nothing runs some times

Regards
Durga Mahesh

>
>
>


view thread (7+ messages)  latest in thread

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], [email protected], [email protected], [email protected]
  Subject: Re: Query optimization
  In-Reply-To: <CAJCZko+jAv98MZJp0T8KthDoWKdmhKTk-XukQJ1CR-v=+mSRhg@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