Created
April 11, 2021 18:55
-
-
Save ctwhome/8125bfa8e88c672a889704061a83a17b to your computer and use it in GitHub Desktop.
Create 1M random numbers
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- create a million random numbers and strings | |
CREATE TABLE items AS | |
SELECT | |
(random()*1000000)::integer AS n, | |
md5(random()::text) AS s | |
FROM | |
generate_series(1,1000000); | |
-- inform planner of big table size change | |
VACUUM ANALYZE; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment