How is the random query performance of mongodb elasticsearch?

  1. first of all, what we do is the examination system, which involves the function of randomly selecting questions. The test questions are saved in mongodb, and the number of test questions is very large. We want to solve the following problems.

    randomly select questions from the test questions bank according to the configuration of the test paper
    want to know the random query performance of mongodb elasticsearch?
    what we know now is that mongodb elasticsearch supports full-text search, and other detailed functions are not very clear. Do you have any good ideas?

May.27,2022
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1c276aa-3385e.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1c276aa-3385e.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?