Why So Many Collisions With The Mariadb 10.2 Rand() Function?
Note: Running MariaDB 10.2.27 on Windows Server 2012 R2 Standard. I wanted to generate random integers for use in MariaDB so I have been experimenting with the MariaDB RAND() funct
Solution 1:
Further experiments with 5.6's RAND indicate that it is good to only 30 bits. That is it has only about one billion distinct values.
File a bug with bugs.mysql.com and/or MariaDB.
30 bits is good enough for most applications. Of those applications for which it is not good enough, most people won't notice its wimpiness.
FLOAT has 24 bits of precision; DOUBLE has 53. So 30 needs DOUBLE, but fails to fill it up.
Post a Comment for "Why So Many Collisions With The Mariadb 10.2 Rand() Function?"