suboptimal index usage

Returns currencies, where currency ID is bid:bitcoin, time start since 2025-10-07 and time start till 2025-10-08, sorted by interval time start: start, duration, currency ID, currency symbol, currency name, USD, open and 3 more fields.

By Aleksey · saved 8 October 2025 · run 1 time · Bitquery API v2

What it returns

Filters

The query

query TradingViewHistory($from: DateTime, $to: DateTime, $resolution: Int, $currencyID: String) {
  Trading {
    Currencies(
      orderBy: {ascending: Interval_Time_Start}
      where: {Interval: {Time: {Duration: {eq: $resolution}, Start: {since: $from, till: $to}}}, Currency: {Id: {is: $currencyID}}}
    ) {
      Interval {
        Time {
          Start
          Duration
        }
      }
      Currency {
        Id
        Symbol
        Name
      }
      Volume {
        Usd
      }
      Price {
        Ohlc {
          Open
          Close
          Low
          High
        }
      }
    }
  }
}

Variables

{
  "resolution": 3600,
  "from": "2025-10-07T08:17:23Z",
  "to": "2025-10-08T08:17:23Z",
  "currencyID": "bid:bitcoin"
}

Similar queries