home

trading

Custom SQL query

Tables

btc_price_history

id, source, price, timestamp_ms, created_at

175,578 rows

capital

id, total_capital, available_capital, updated_at

0 rows

circuit_breaker_events

id, bot_id, triggered_at, daily_pnl, threshold, unrealized_pnl, realized_pnl

0 rows

daily_stats

id, date, bot_id, day_of_week, trades_count, wins, losses, pnl_usd, gross_profit, gross_loss, unrealized_pnl, circuit_breaker_triggered

38 rows

exposure_snapshots

id, bot_id, timestamp, up_exposure_usd, down_exposure_usd, net_exposure_usd, up_positions_count, down_positions_count

5,571 rows

markets

slug, market_type, title, start_time, end_time, btc_price_to_beat, btc_price_source, condition_id, up_token_id, down_token_id, created_at

76 rows

monthly_stats

id, bot_id, year, month, trades_count, wins, losses, pnl_usd, gross_profit, gross_loss

31 rows

orderbook_snapshots

id, trade_id, position_id, snapshot_type, token_id, direction, timestamp_ms, best_bid, best_ask, spread, mid_price, bid_depth_5, ask_depth_5, obi, raw_bids, raw_asks, created_at

7,858 rows

orders

id, bot_id, market_id, token_id, direction, side, order_type, price, size, status, filled_size, filled_price, external_id, error_message, created_at, updated_at

0 rows

positions

id, bot_id, market_id, token_id, direction, status, entry_price, entry_time, shares, cost_basis, remaining_shares, tp1_hit, tp2_hit, tp1_exit_price, tp2_exit_price, entry_order_id, exit_order_ids, created_at, updated_at, closed_at, price_5s_before, price_30s_before, price_volatility, orderbook_imbalance, momentum_ticks, btc_price_to_beat, btc_price_at_entry, btc_delta_at_entry, time_remaining_at_entry, entry_number, is_reentry, previous_position_id, time_since_last_exit_seconds, last_exit_reason, last_exit_pnl_pct, calculated_position_size, zone_position_pct, momentum_detected, opposite_side_price, dead_zone_seconds_used

1,556 rows

session_stats

id, bot_id, session, trades_count, wins, losses, pnl_usd, gross_profit, gross_loss, overlap_trades, overlap_pnl, avg_session_progress

118 rows

sqlite_sequence

name, seq

5 rows

trades

id, bot_id, position_id, market_id, direction, entry_price, exit_price, entry_time, exit_time, shares_sold, pnl_usd, pnl_pct, exit_reason, order_id, gross_pnl_usd, entry_fee_usd, exit_fee_usd, total_fees_usd, entry_execution_mode, exit_execution_mode, exit_orderbook_imbalance, exit_time_to_fill_ms, exit_maker_attempted, exit_maker_filled, entry_session, exit_session, entry_session_overlap, exit_session_overlap, entry_session_progress, market_slug

5,068 rows

trading_stats

bot_id, total_trades, wins, losses, total_pnl_usd, total_pnl_pct, gross_profit, gross_loss, tp1_count, tp2_count, tp3_count, sl_count, trailing_sl_count, manual_count, total_fees_paid, total_gross_pnl, total_position_duration_seconds, avg_position_duration_seconds, reentry_trades_count, reentry_pnl_usd, reentry_win_rate, dynamic_size_avg, dynamic_size_min, dynamic_size_max

38 rows

weekly_stats

id, bot_id, year, month, week_of_month, trades_count, wins, losses, pnl_usd, gross_profit, gross_loss

31 rows

Powered by Datasette · Queries took 16.063ms