add index on block number to address token balances

pull/1444/head
Ayrat Badykov 6 years ago
parent 5b5a0b3cfe
commit caa40cc017
No known key found for this signature in database
GPG Key ID: B44668E265E9396F
  1. 2
      apps/explorer/mix.exs
  2. 7
      apps/explorer/priv/repo/migrations/20190214135850_add_index_on_block_number_to_address_token_balances.exs

@ -91,7 +91,7 @@ defmodule Explorer.Mixfile do
{:math, "~> 0.3.0"}, {:math, "~> 0.3.0"},
{:mock, "~> 0.3.0", only: [:test], runtime: false}, {:mock, "~> 0.3.0", only: [:test], runtime: false},
{:mox, "~> 0.4", only: [:test]}, {:mox, "~> 0.4", only: [:test]},
{:poison, "~> 3.1", only: [:test]}, {:poison, "~> 3.1"},
{:postgrex, ">= 0.0.0"}, {:postgrex, ">= 0.0.0"},
# For compatibility with `prometheus_process_collector`, which hasn't been updated yet # For compatibility with `prometheus_process_collector`, which hasn't been updated yet
{:prometheus, "~> 4.0", override: true}, {:prometheus, "~> 4.0", override: true},

@ -0,0 +1,7 @@
defmodule Explorer.Repo.Migrations.AddIndexOnBlockNumberToAddressTokenBalances do
use Ecto.Migration
def change do
create(index(:address_token_balances, [:block_number]))
end
end
Loading…
Cancel
Save