Skip to content

How To Subtract

  • Excel
  • Google Sheets
  • Calculators
  • Other Apps
  • Programming
  • About

Programming

How to subtract numbers and dates in Python, JavaScript, Java, SQL, Bash and VBA.

Programming

How to Subtract in SQL

November 19, 2026 by Matthew Burleigh

Subtract in SQL with the minus operator, subtract dates in SQL Server, PostgreSQL, MySQL and SQLite, compare rows with LAG and remove rows with EXCEPT or MINUS.

Categories Programming
Programming

How to Subtract in Python

November 19, 2026 by Matthew Burleigh

Subtract in Python 3 with the minus operator, -= and operator.sub, plus exact money math with Decimal, date gaps, set and list differences, and error fixes.

Categories Programming
Programming

How to Subtract in JavaScript

November 19, 2026 by Matthew Burleigh

Subtract in JavaScript with the minus operator, -= and –. Covers form input strings, arrays, date differences, NaN, BigInt errors and decimal rounding.

Categories Programming

Browse topics

  • Calculators (4)
  • Excel (6)
  • Google Sheets (4)
  • Other Apps (3)
  • Programming (3)

About this site

How To Subtract has step-by-step guides for subtracting in Excel, Google Sheets, calculators and code, written by Matthew Burleigh. Learn more.

  • About
  • Contact
  • Privacy Policy
  • Terms of Use
  • Disclaimer
© 2026 How To Subtract