Random Dates and Numbers in PostgreSQL with the RANDOM() Function

Geekery

Working with the random() function in PostgreSQL can be a bit tricky if you’re trying to populate a table. The random() function in PostgreSQL will return a number between 0 and 1 like so: SELECT RANDOM(); random ——————- 0.115072432027698 (1 ROW)SELECT RANDOM(); random ——————- 0.115072432027698 (1 row) If you’re trying to get a whole number… Read more »