D
D
Denis2018-08-31 19:49:04
PostgreSQL
Denis, 2018-08-31 19:49:04

Is it possible to speed up the query to the database (add indexes)?

Hello.
T-ca:

id (uuid)
crash_id (uuid)
value (numeric)
date (timestamp)

Request
select crash_id, value, date FROM table1
where crash_id = any('{'856F1768-BBDC-4755-8256-080BFA8EB0BA'}')
and date > '[some date]'

Experimented with indexes, i.e. added CREATE INDEX some_pkey ON table1(crash_id , date)
but, something did not work out. Query Plan shows Seq Scan .
Is there any way to speed up the request?

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question