Bug #10342 disable keys for all tables

Submitted: 3 May 2005 16:37 Modified: 3 May 2005 16:46
Reporter: Jacek Becla Email Updates:
Status: Verified Impact on me:
None 
Category:MySQL Server: DDL Severity:S4 (Feature request)
Version: OS:Any
Assigned to: CPU Architecture:Any

[3 May 2005 16:37] Jacek Becla
Description:
Disabling keys for a table speeds up data loading. It would be handy to be able to disable/enable keys for all tables in a given database with a single command, something like 'ALTER DATABASE X DISABLE KEYS', 'ALTER TABLE X ENABLE KEYS'. This could internally iterate over all tables in database X and enable/disable keys for each of them. 

How to repeat:
N/A
[3 Oct 2008 19:10] Konstantin Osipov
Workaround: use a small stored procedure with Dynamic SQL.
Select from INFORMATION_SCHEMA.TABLES where schema_name=db, for each selected table run PREPARE stmt, EXECUTE stmt;
[3 Oct 2008 19:11] Konstantin Osipov
Needs new triage, provided a workaround.

Portions of this website are copyright © 2001, 2002 The PHP Group

Page generated in 0.052 sec. using MySQL 8.4.7-u6-cloud

Timestamp references displayed by the system are UTC.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.