M
M
m0dE2016-09-22 21:35:59
PostgreSQL
m0dE, 2016-09-22 21:35:59

Occasionally a very long UPDATE transaction?

Good afternoon! With a heavy load on the server, some requests are executed for a very long time (up to 20s). View request:

UPDATE "table" SET
      "views"="views"+1
WHERE "sid"=:sid AND "pid"=:pid

Indexes stand both on sid and on pid
Because of what such behavior can be?
The table being updated is very small

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alibek Beldinov, 2016-09-23
@Neuyazvimy1

You most likely did not tune your database. This is not MySQL that works out of the box, it needs to be configured.
https://wiki.postgresql.org/wiki/Tuning_Your_Postg...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question