Skip to main content
The prediction_markets.trades table holds Polymarket and Kalshi trades in one table. It has one row per taker fill, unique on (venue, block_month, trade_id). The taker is the side whose order filled against a resting order. Polymarket Combos (multi-leg parlays) are included; they have is_parlay = TRUE in markets. Each trade appears once, so SUM(amount_usd) gives venue volume without extra filters. Polymarket’s maker rows are only in the venue table, polymarket_polygon.market_trades, where is_taker_side = FALSE. Three columns describe each trade:
  • price is always the probability of Yes in [0, 1], comparable across venues and sides.
  • outcome_side is the side of the market the traded contract belongs to (yes or no).
  • taker_side is whether the taker bought or sold that contract (BUY or SELL).
taker_fill_price is the price of the contract actually traded (price for a Yes contract, 1 - price for a No contract), so taker_fill_price × num_contracts = amount_usd on every row. On Polymarket rows, event_id is Polymarket’s own event id, the same value as prediction_markets.markets.event_id.
Kalshi reports every trade as a purchase of the side the taker ends up holding. So taker_side is always BUY on Kalshi, and closing a Yes position shows as a BUY with outcome_side = 'no'. Kalshi also reports one row per taker-maker pair. Compare sums across venues, not row counts.

Table Schema

Table sample

Query performance

The table is partitioned by block_month. Always filter on block_month or executed_at.

Example queries

Previous version

Columns of the previous version, for queries that still use it. The migration guide maps each old column to its new name.