my $query = $dbh->prepare('SHOW TABLES'); if (defined($query)) { $query->execute(); my @row; while (@row = $query->fetchrow_array()) { $sql = qq|delete from $row[0]|; $sth = $dbh->prepare($sql) or die "Cannot prepare: " . $dbh->errstr(); $sth->execute() or die "" . $sth->errstr();
In reply to Re^2: Deleting all from all tables in MYSQL
by justin423
in thread Deleting all from all tables in MYSQL
by justin423
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |