From: Wim Bertels <wim.bertels@ucll.be>
To: kenny.bachman17@gmail.com <kenny.bachman17@gmail.com>
To: pgsql-admin@lists.postgresql.org <pgsql-admin@lists.postgresql.org>
Subject: Re: Postgresql 14 performance
Date: Sun, 21 Aug 2022 17:06:35 +0000
Message-ID: <15d5ba26a5d3b8fef5e88372f8438840bee3d36f.camel@ucll.be> (raw)
In-Reply-To: <CAC0w7LL+uFgPvctiHMxrVZV-DnNVg2K_wFaeZwM96XQFkjk1uA@mail.gmail.com>
References: <CAC0w7LL+uFgPvctiHMxrVZV-DnNVg2K_wFaeZwM96XQFkjk1uA@mail.gmail.com>
Hello Kenny,
have you tried to correlate with the system load for example?
also, it is normal to have variations,
although big variations under the same circumstances might indicate
another problem on the system (somewhere in your hw/sw stack)
--
a quick look at the query + plan:
..WHERE "Extent1"."DdoId" = 1506074 OR "Extent1"."DdoId" IS NULL AND
1506074 IS NULL LIMIT 1;
1506074 IS NULL is always false (generated query?)
(never executed lines, ERP_WORK_ORDER_DDO_INFO does not seem to a
regular table, hence the query plan, (there a few highlighting
tools/sites for the query plan you could also check))
mvg,
Wim
Kenny Bachman schreef op zo 21-08-2022 om 19:05 [+0300]:
> Hi Team,
>
> Have a lovely Sunday.
> I have a problem with PostgreSQL performance. I am using PostgreSQL
> 14.5 on Linux physical server. My query was taking 1 or 2 seconds
> yesterday, but today it is taking 5-6 seconds. Also, nothing has
> changed in the database. Also, when I run the query for the second
> time, the query runs for the same time, so I expect it to be more
> performant the second time because of the cache.
> (the database cache hit ratio is 97,8)
>
> Lastly, some other queries take milliseconds normally, but sometimes
> they take minutes. I didn't understand why this is happening. (There
> is no lock, no table bloating and up to date analyze)
>
>
> I am adding the explain analyze output as an attachment.
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: pgsql-admin@postgresql.org
Cc: wim.bertels@ucll.be, kenny.bachman17@gmail.com, pgsql-admin@lists.postgresql.org
Subject: Re: Postgresql 14 performance
In-Reply-To: <15d5ba26a5d3b8fef5e88372f8438840bee3d36f.camel@ucll.be>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox