pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Justin Pryzby <pryzby@telsasoft.com>
To: dangal <danielito.gallo@gmail.com>
Cc: pgsql-performance@postgresql.org
Subject: Re: slow query
Date: Fri, 3 Apr 2020 11:07:47 -0500
Message-ID: <20200403160747.GP14618@telsasoft.com> (raw)
In-Reply-To: <1585929829525-0.post@n3.nabble.com>
References: <1585929829525-0.post@n3.nabble.com>

On Fri, Apr 03, 2020 at 09:03:49AM -0700, dangal wrote:
> Dear I have a question to ask you
> I am having a slow problem with a query and I am seeing with the explain that the current cost and time differ by 4 times

The "cost" is in arbitrary units, and the time is in units of milliseconds.
The cost is not an expected duration.

> Postgres version 9.5.16 in centos 7.6
> To try to solve this run the statistics to the table and the same problem
> remains
> It's a very big table 2 billion tuples
> Do you have any idea what I can do to improve
> Thank you very much for your time
> Any data you need I can provide

Please check here.
https://wiki.postgresql.org/wiki/Slow_Query_Questions

> I share a part of the explain

It's not very useful to see a fragment of it.

-- 
Justin





view thread (112+ messages)  latest in thread

Message-ID: <20200403160747.GP14618@telsasoft.com>
Permalink:  ../20200403160747.GP14618@telsasoft.com/
Also on:    postgresql.org/message-id/20200403160747.GP14618@telsasoft.com

 · 

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: pgsql-performance@postgresql.org
  Cc: pryzby@telsasoft.com, danielito.gallo@gmail.com
  Subject: Re: slow query
  In-Reply-To: <20200403160747.GP14618@telsasoft.com>

* 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