Fixed hnsw graph not repaired error with HNSW vacuuming - fixes #993

This commit is contained in:
Andrew Kane
2026-06-30 00:34:01 -07:00
parent f1dd4e3b03
commit 497db7976c
2 changed files with 9 additions and 0 deletions

View File

@@ -80,6 +80,14 @@ RemoveHeapTids(HnswVacuumState * vacuumstate)
if (!HnswIsElementTuple(etup))
continue;
/*
* Skip deleted tuples. It is important they are not added to the
* deleted hash to avoid false positives in NeedsUpdated and
* ConfirmRepaired.
*/
if (etup->deleted)
continue;
if (ItemPointerIsValid(&etup->heaptids[0]))
{
for (int i = 0; i < HNSW_HEAPTIDS; i++)