Skip to content
ENExplore Calculators

Query Scan Cost Calculator

Work out query scan cost instantly with clear inputs, formula shown and shareable results.

About Query Scan Cost Calculator

Scan-based pricing charges per byte read, so cost is entirely determined by how much data each query touches. Partition pruning and columnar projection are the levers: 92 percent pruning turns a 20 TB table scan into 1.6 TB, and selecting three columns from a hundred cuts it again. Without pruning, 800 daily queries over 20 TB would cost over two million a month.

Formula

Scan cost

scanned per query = table size x (1 - pruning); monthly = scanned x queries x 30.44 x price per TB

Worked example

With the default values below, Query Scan Cost Calculator returns Monthly query scan cost of $194,816.00. Change any input above and every figure here is recalculated in your browser.

Inputs used

Table sizeminimum 0.001 TB
20 TB
Queries per dayminimum 0
800
Data eliminated by partition pruningaccepts 0–99.99 %
92 %
Price per TB scannedminimum 0
5

Results

Monthly query scan cost
$194,816.00
Data scanned per query
1.6000 TB
Total data scanned per month
38,963.2 TB
Saving from partition pruning
$2,240,384.00

Step by step

  1. 1Values used
  2. 2Scan cost
  3. 3Monthly query scan cost= 194,816.00
  4. 4Data scanned per query= 1.6000 TB
  5. 5Total data scanned per month= 38,963.2 TB
  6. 6Saving from partition pruning= 2,240,384.00

Assumptions and limits

  • The result is derived only from the 4 inputs listed above. Anything not among them is not part of the calculation.
  • In particular, this calculator does not take inflation, tax, fees or charges or compounding frequency into account.
  • Figures are rounded for display to 4 decimal places, so totals built from several rounded parts can differ slightly from the unrounded arithmetic.

How these calculators are built and tested is described on the Methodology page. If a figure looks wrong, please report it.

Frequently Asked Questions

How is pruning maximised?

Partition on the column most queries filter on, usually a date, and ensure the filter is a literal predicate the planner can evaluate — a function applied to the partition column disables pruning.

Does SELECT * matter with columnar storage?

Enormously. Columnar formats only read the columns referenced, so selecting all of them can multiply the scan by ten or more.

Query Scan Cost Calculator | Calcrivo