List:General Discussion« Previous MessageNext Message »
From:Dicky Wahyu Purnomo Date:July 26 2002 1:22am
Subject:Re: TRUNCATE TABLE
View as plain text  
Pada Thu, 25 Jul 2002 22:27:50 +0300
Andrew Sitnikov <sitnikov@stripped> menulis :

> Hello mysql,
> 
>   Why after TRUNCATE TABLE data file with indexes not freed ?
>   and TRUNCATE TABLE is very slow ...
> 
>   MySQL 3.23.51+InnoDB
>   OS: Linux 2.4.18/ReiserFS

it's better (faster) to do it this way :

- mysqldump -d -p <DB> <table> > file.sql
- cd <mysql_data_dir>/<db_dir>
- rm <table_name>.*   .......     or    
- mv <table_name>.* <to_somewhere_else>
- mysql -p <DB> < file.sql


-- 
printk("??? No FDIV bug? Lucky you...\n");
	2.2.16 /usr/src/linux/include/asm-i386/bugs.h
 
MySQL 3.23.51 : up 34 days, Queries : 354.789 per second (avg).

--
Dicky Wahyu Purnomo - System Administrator
PT FIRSTWAP : Jl Kapt. Tendean No. 34 - Jakarta Selatan (12790)
Phone : +62 21 79199577 - Web : http://1rstwap.com

Thread
TRUNCATE TABLEAndrew Sitnikov25 Jul
  • Re: TRUNCATE TABLEDicky Wahyu Purnomo26 Jul
  • Re: TRUNCATE TABLEBenjamin Pflugmann26 Jul
    • Re[2]: TRUNCATE TABLEAndrew Sitnikov26 Jul
      • Re: Re[2]: TRUNCATE TABLEBenjamin Pflugmann26 Jul
    • Re[2]: TRUNCATE TABLEAndrew Sitnikov26 Jul
      • Re: Re[2]: TRUNCATE TABLEBenjamin Pflugmann26 Jul
        • Re[4]: TRUNCATE TABLEAndrew Sitnikov28 Jul
          • Re: Re[4]: TRUNCATE TABLEBenjamin Pflugmann29 Jul