How to calculate Working Capital

Working capital is current assets minus current liabilities: the short-term resources available to run the business.

Formula

Working capital = current assets − current liabilities

SQL query

This example assumes: balances(as_of, account_class, amount) with account_class in 'current_asset', 'current_liability'. It is written in PostgreSQL syntax; date functions differ slightly in MySQL, BigQuery and SQLite, and your column names will differ from these.

SELECT as_of,
       SUM(amount) FILTER (WHERE account_class = 'current_asset')
     - SUM(amount) FILTER (WHERE account_class = 'current_liability') AS working_capital
FROM balances
GROUP BY as_of
ORDER BY as_of;

Common mistakes that make Working Capital wrong

  • A positive number does not mean cash is available; inventory and receivables can be hard to turn into cash.
  • Classification of current vs non-current items varies; use consistent mapping.
  • Compare at the same point each period to avoid seasonal swings.

Ask for Working Capital in plain English

Instead of writing the query yourself, you can type the question. SchemaChat turns it into SQL against your connected database or uploaded file, runs it, and shows the SQL and the figures it used so you can check the answer before you share it. It does not replace your judgement about the definition: check that the query matches the formula your business uses.

  • What was working capital at each month end?
  • How much of current assets is cash versus receivables?

Frequently asked questions

What is Working Capital?
Working capital is current assets minus current liabilities: the short-term resources available to run the business.
How do you calculate Working Capital?
Working capital = current assets − current liabilities. The SQL example on this page shows the same calculation against a simple table.
What commonly goes wrong when calculating Working Capital?
A positive number does not mean cash is available; inventory and receivables can be hard to turn into cash.