diff --git a/experimental/plugins/postgres_storage/src/postgres_storage.rs b/experimental/plugins/postgres_storage/src/postgres_storage.rs index 01f66362a1..0d5e510aff 100644 --- a/experimental/plugins/postgres_storage/src/postgres_storage.rs +++ b/experimental/plugins/postgres_storage/src/postgres_storage.rs @@ -146,7 +146,7 @@ const _CREATE_SCHEMA: [&str; 12] = [ ON UPDATE CASCADE )", "CREATE INDEX IF NOT EXISTS ix_tags_encrypted_name ON tags_encrypted(name)", - "CREATE INDEX IF NOT EXISTS ix_tags_encrypted_value ON tags_encrypted(value)", + "CREATE INDEX IF NOT EXISTS ix_tags_encrypted_value ON tags_encrypted(sha256(value))", "CREATE INDEX IF NOT EXISTS ix_tags_encrypted_item_id ON tags_encrypted(item_id)", "CREATE TABLE IF NOT EXISTS tags_plaintext( name BYTEA NOT NULL,