Company
Date Published
Author
Yevgeny Rizhkov
Word count
589
Language
English
Hacker News points
None

Summary

Aerospike secondary indexes can significantly speed up Trino SQL queries by allowing for efficient querying of non-primary key bins. By leveraging Aerospike's enhanced secondary index functionality, users can accelerate their secondary key queries at scale. Creating a secondary index on a high-cardinality bin can help mitigate the performance penalty associated with full table scans, and the Trino connector automatically analyzes queries to apply secondary indexes if available. Users can declare specific secondary indexes to use in queries, and the connector will select the most suitable one based on availability. This feature can lead to substantial performance gains, as demonstrated by example queries that show a significant improvement when using secondary indexes compared to full table scans.