Performance Improvement in SQL

From: Lucas Souza Cruz <souzacruz001(at)gmail(dot)com>
To: pgsql-bugs(at)postgresql(dot)org
Subject: Performance Improvement in SQL
Date: 2016-03-10 14:44:06
Message-ID: CAG84nv9yQrSeOm7Ua63BVu7tGUEj0O_Bya9v+v=YDWtLcQG3WA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Hi, my name is Lucas Souza and i live in Goiânia, Brazil.
Recently, i had a problem with an SQL due to delay.

The part of the SQL that was slow is: ' WHERE idprod = 123456 '.

In this line, the execution was of fifteen seconds.

And i try this: ' WHERE CASE WHEN idprod = 123456 THEN TRUE ELSE FALSE END
= TRUE '.

Now, the execution was half of one second.

I sending this e-mail because i believe that the PostgreSQL Community can
improvement the perfomance of database

If this solution exists, sorry for this e-mail.

And sorry too for my english.

Thanks.
Lucas de Souza Cruz

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Léonard Benedetti 2016-03-10 14:44:17 Re: BUG #13440: unaccent does not remove all diacritics
Previous Message Léonard Benedetti 2016-03-10 14:35:00 Re: BUG #13440: unaccent does not remove all diacritics