Blog

Your dream job? Lets Git IT.
Interactive technical interview preparation platform designed for modern developers.

XGitHub

Platform

  • Categories

Resources

  • Blog
  • About the app
  • FAQ
  • Feedback

Legal

  • Privacy Policy
  • Terms of Service

© 2025 LetsGit.IT. All rights reserved.

LetsGit.IT/Categories/Databases
Databaseshard

Soft delete vs hard delete — what’s the trade-off?

Tags
#soft-delete#data-retention#auditing
Back to categoryPractice quiz

Answer

Soft delete marks a row as deleted (e.g., `deleted_at`) so you can restore/audit, but it complicates queries and indexes (you must filter out deleted rows). Hard delete removes data and simplifies queries, but you lose history unless you archive elsewhere.