"Steve 'Hara" <sohara (AT) pivotal-solutions (DOT) co.ukwrote: The standard SQLite function random() is actually seeded by the current time and date every time you open a database. FWIW, the random() function in SQLite uses a cryptographic PRNG and (at least on Unix) is seeded using /dev/urandom if that device is available. So it should give you very good randomness.