Re: MySQL million tables
От | Greg Sabino Mullane |
---|---|
Тема | Re: MySQL million tables |
Дата | |
Msg-id | da365fd5acda3d5fb7deabcb0a81172d@biglumber.com обсуждение исходный текст |
Ответ на | MySQL million tables (Christopher Kings-Lynne <chriskl@familyhealth.com.au>) |
Ответы |
Re: MySQL million tables
|
Список | pgsql-advocacy |
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 I kicked this off last night before bed. It ran much quicker than I thought, due to that 27 hour estimate. Total time: 23 minutes 29 seconds :) I committed every 2000 table commits. It could probably be made to go slightly faster, as this was an out-of-the-box Postgres database, with no postgresql.conf tweaking. I simply piped a text file into psql for the testing, from the outout of a quick perl script: my $max = 1_000_000; my $check = 2_000; print "BEGIN;\n"; for my $num (1..$max) { print "CREATE TABLE foo$num (a smallint);\n"; $num%$check or print "COMMIT;\nBEGIN;\n"; } print "COMMIT;\n"; And the proof: greg=# select count(*) from pg_class where relkind='r' and relname ~ 'foo' count - --------- 1000000 Maybe I'll see just how far PG *can* go next. Time to make a PlanetPG post, at any rate. - -- Greg Sabino Mullane greg@turnstep.com PGP Key: 0x14964AC8 200603090720 http://biglumber.com/x/web?pk=2529DF6AB8F79407E94445B4BC9B906714964AC8 -----BEGIN PGP SIGNATURE----- iD8DBQFEEB2yvJuQZxSWSsgRAvUbAKCzO80prZ4DX4l3iT0Dh+Re5M4TpACfW95z y4cdkQjw2ubAP4btMwSw5iw= =Ginx -----END PGP SIGNATURE-----
В списке pgsql-advocacy по дате отправления: