cleaning mysql links