forked from LBRYCommunity/lbry-sdk
include claim_hash in txo_claim_chahges postgres index
This commit is contained in:
parent
b61424979d
commit
d1ac066c6d
1 changed files with 1 additions and 1 deletions
|
@ -110,7 +110,7 @@ pg_add_txo_constraints_and_indexes = [
|
||||||
f"WHERE spent_height = 0 AND txo_type={TXO_TYPES['support']};",
|
f"WHERE spent_height = 0 AND txo_type={TXO_TYPES['support']};",
|
||||||
# for finding modified claims in a block range
|
# for finding modified claims in a block range
|
||||||
f"CREATE INDEX txo_claim_changes "
|
f"CREATE INDEX txo_claim_changes "
|
||||||
f"ON txo (height DESC) INCLUDE (txo_hash) "
|
f"ON txo (height DESC) INCLUDE (claim_hash, txo_hash) "
|
||||||
f"WHERE spent_height = 0 AND txo_type IN {tuple(CLAIM_TYPE_CODES)};",
|
f"WHERE spent_height = 0 AND txo_type IN {tuple(CLAIM_TYPE_CODES)};",
|
||||||
# for finding claims which need support totals re-calculated in a block range
|
# for finding claims which need support totals re-calculated in a block range
|
||||||
f"CREATE INDEX txo_added_supports_by_height ON txo (height DESC) "
|
f"CREATE INDEX txo_added_supports_by_height ON txo (height DESC) "
|
||||||
|
|
Loading…
Reference in a new issue