SyntaxFix
Write A Post
Hire A Developer
Questions
Or at a shell prompt, in just two lines, without a named temporary file, assuming $db is the SQLite database name:
echo "SELECT 'DROP TABLE ' || name ||';' FROM sqlite_master WHERE type = 'table';" | sqlite3 -readonly "$db" | sqlite3 "$db"