Re: Slow delete
От | Andrew Hammond |
---|---|
Тема | Re: Slow delete |
Дата | |
Msg-id | 41B5E4FB.7000305@ca.afilias.info обсуждение исходный текст |
Ответ на | Slow delete ("Colin Gillespie" <C.Gillespie@newcastle.ac.uk>) |
Список | pgsql-novice |
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Colin Gillespie wrote: | Dear All, | | I have four tables linked together with FK. An example is, deleting an id | in one table, deletes 1,000,000 rows in all the others. However, this | operation takes 2-3mins (currently this more or less empties the database.) | Is this slow? Depends on what hardware you're using. It sounds like you've done the right thing so far. I assume you've run explain on the stuff involved to make sure it's actually using those indexes. | | I have checked that the FK have been indexed and that they have been declared intergers. A full vacuum has also been performed. | | Does anyone have any suggestions on how to speed this up? | | Thanks | | Colin | | ---------------------------(end of broadcast)--------------------------- | TIP 4: Don't 'kill -9' the postmaster - -- Andrew Hammond 416-673-4138 ahammond@ca.afilias.info Database Administrator, Afilias Canada Corp. CB83 2838 4B67 D40F D086 3568 81FC E7E5 27AF 4A9A -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.5 (GNU/Linux) iD8DBQFBteT6gfzn5SevSpoRAkCCAKCV4Zojyw52c9POrjoHsnK0zjQDEgCgoQZw hdDUThg/ojIojRWrLtiKBZg= =Xs0l -----END PGP SIGNATURE-----
В списке pgsql-novice по дате отправления: