pepkit / pepdbagent

Database for storing sample metadata
BSD 2-Clause "Simplified" License
2 stars 1 forks source link

Add more efficient index to a description #88

Closed khoroshevskyi closed 6 months ago

khoroshevskyi commented 1 year ago

Super fast search if we will ad this index: CREATE EXTENSION pg_trgm; CREATE INDEX trgm_index_description ON projects USING gin (description gin_trgm_ops);

https://niallburkley.com/blog/index-columns-for-like-in-postgres/

khoroshevskyi commented 11 months ago

Only superuser can add this index. @khoroshevskyi don't have rights to add it

nleroy917 commented 6 months ago

I want the PEPhub search to be nearly instant, and right now the SQL-based searches are too slow. They take about 4-5 seconds to complete), so I'll bump this

nsheff commented 6 months ago

Ok, index created... did that help?

khoroshevskyi commented 6 months ago

Yes, now search is very fast. Thank you