aboutsummaryrefslogtreecommitdiff
path: root/src/mintdb/plugin_mintdb_postgres.c
diff options
context:
space:
mode:
authorFournier Nicolas <nicolas.fournier@ensta-paristech.fr>2015-07-31 15:06:07 +0200
committerFournier Nicolas <nicolas.fournier@ensta-paristech.fr>2015-07-31 15:06:07 +0200
commitc6d7c6adb2075422087f8f6b1159f28a00bab276 (patch)
treeb5a97b1a6f5a552b187f2012d511c5fce826a06f /src/mintdb/plugin_mintdb_postgres.c
parentaa563f3e4a6c5fb2a458b12a97dc130002ea3457 (diff)
added index for deposits table
Diffstat (limited to 'src/mintdb/plugin_mintdb_postgres.c')
-rw-r--r--src/mintdb/plugin_mintdb_postgres.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/mintdb/plugin_mintdb_postgres.c b/src/mintdb/plugin_mintdb_postgres.c
index ac0fcb7ea..20d65bc92 100644
--- a/src/mintdb/plugin_mintdb_postgres.c
+++ b/src/mintdb/plugin_mintdb_postgres.c
@@ -404,6 +404,9 @@ postgres_create_tables (void *cls,
",coin_sig BYTEA NOT NULL CHECK (LENGTH(coin_sig)=64)"
",wire TEXT NOT NULL"
")");
+ /* Index for get_deposit statement on coin_pub, transactiojn_id and merchant_pub */
+ SQLEXEC_INDEX("CREATE INDEX deposits_coin_pub_index "
+ "ON deposits(coin_pub, transaction_id, merchant_pub)");
#undef SQLEXEC
#undef SQLEXEC_INDEX