← Learn
Dangerous
psql -c "UPDATE users SET email = 'x@example.com';"

cross-platform · sql · Beginner

Rewrites the email column for every row because the statement has no WHERE clause. A missing WHERE is the most common way a routine-looking update becomes a table-wide overwrite.

Signals to notice

  • no WHERE clause, so the update applies to every row in the table
  • the original values are overwritten rather than copied aside

Think you can spot these under time pressure?

Start Training

More File System