Amino Interview Question

How can we query data efficiently from large data set?