Am 04.11.2011 08:22, schrieb Adarsh Sharma: > delete from metadata where id>2474; > but it takes hours to complete. > > CREATE TABLE `metadata` ( > `meta_id` bigint(20) NOT NULL AUTO_INCREMENT, > `id` bigint(20) DEFAULT NULL, > `url` varchar(800) DEFAULT NULL, > `meta_field` varchar(200) DEFAULT NULL, > `meta_value` varchar(2000) DEFAULT NULL, > `dt_stamp` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP, > PRIMARY KEY (`meta_id`) > ) ENGINE=InnoDB AUTO_INCREMENT=388780373 ; > > Please let me know any quickest way to do this. > I tried to create indexes in these tables on id, but this too takes time
well i guess you have to sit out add the key wrong table design having an id-column without a key or something weird in the application not using the primary key for such operations
signature.asc
Description: OpenPGP digital signature