Hi.

On Sun 2003-01-12 at 22:01:37 -0500, [EMAIL PROTECTED] wrote:
> On Sun, Jan 12, 2003 at 08:12:35PM -0700, Rodney Broom wrote:
> > > I'm trying to delete 5 million rows...
[...]
> If I was deleting things regularly, I'd have to delete maybe a couple
> hundred thousand rows every day.
[...]
> When I say "blocked", I mean e.g. another process tries to SELECT from
> another table in the database, but it takes way too long.

If you are absolutely sure that the other queries don't related to the
deleting query at all, it means they are slow, because your disks are
too stressed.

> > > Any suggestions on how I can delete those rows without causing a lot
> > > of downtime?

As http://www.mysql.com/doc/en/DELETE.html suggests, you can use LIMIT
with DELETE in order to restrict the time a DELETE needs by running
it in batches.

HTH,

        Benjamin.

-- 
[EMAIL PROTECTED]

---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to