From af24dbb836593eeb4c7bea9a317fb42e71868cbc Mon Sep 17 00:00:00 2001 From: 1000101 Date: Mon, 19 Feb 2024 14:16:19 +0100 Subject: [PATCH] docs(sql): add new indices --- CHANGELOG.md | 1 + README.md | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index b34ce122..50a17d73 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -16,6 +16,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - support for Cardano Sanchonet - translation of cost models from numerical IDs to strings, required for `cardano-db-sync 13.1.1.3` and newer [#130](https://github.com/blockfrost/blockfrost-backend-ryo/pull/130) +- indices improving `/assets/{asset}` when querying CIP68 assets and `/txs/{tx_hash}` with redeemers ### Changed diff --git a/README.md b/README.md index 06a75984..5a87575f 100644 --- a/README.md +++ b/README.md @@ -96,6 +96,10 @@ CREATE UNIQUE INDEX IF NOT EXISTS bf_u_idx_epoch_stake_epoch_and_id ON epoch_sta CREATE INDEX IF NOT EXISTS bf_idx_reference_tx_in_tx_in_id ON reference_tx_in (tx_in_id); CREATE INDEX IF NOT EXISTS bf_idx_collateral_tx_in_tx_in_id ON collateral_tx_in (tx_in_id); CREATE INDEX IF NOT EXISTS bf_idx_redeemer_script_hash ON redeemer USING HASH (encode(script_hash, 'hex')); +CREATE INDEX IF NOT EXISTS bf_idx_redeemer_tx_id ON redeemer USING btree (tx_id); +CREATE INDEX IF NOT EXISTS bf_idx_col_tx_out ON collateral_tx_out USING btree (tx_id); +CREATE INDEX IF NOT EXISTS bf_idx_ma_tx_mint_ident ON ma_tx_mint USING btree (ident); +CREATE INDEX IF NOT EXISTS bf_idx_ma_tx_out_ident ON ma_tx_out USING btree (ident); ``` ### Docker