Ad Widget

Collapse

Delete data from history

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • jungleslow
    Junior Member
    • Mar 2013
    • 6

    #1

    Delete data from history

    Hello,
    I tried to delete data on history_uint with :
    Code:
    DELETE history_uint.* FROM history_uint LEFT JOIN items ON history_uint.itemid = items.itemid WHERE items.itemid IS NULL ;
    I was waiting.. And then after two hours I lost the connexion.
    So I tried to launch again the MySQL request but now I have an error :
    Code:
    ERROR 1205 (HY000): Lock wait timeout exceeded; try restarting transaction
    I changed in my.cnf the timeout to 500 :
    Code:
    innodb_lock_wait_timeout = 500
    But still the same error after 500 seconds :/

    Code:
    select count(itemid) from history_uint where itemid=34321;
    +---------------+
    | count(itemid) |
    +---------------+
    |        125743 |
    +---------------+
    1 row in set (6 min 30.41 sec)
    
    mysql> delete from history_uint where itemid=34321;
    ERROR 1205 (HY000): Lock wait timeout exceeded; try restarting transaction
    mysql> select count(itemid) from history_uint where itemid=34321;
    +---------------+
    | count(itemid) |
    +---------------+
    |        125743 |
    +---------------+
    1 row in set (4 min 41.07 sec)
    Can you tell me how to fix this please ?
    Thanks !
Working...