basquetWi + New ticket
venus VENUS-142

Cleanup: Puia has 2 non-deleted titular userRoles rows (likely dupe)

Done normal dvdb-venus-cc

db-venus flagged during VENUS-141 design: Sebastián Puia holds 2 non-deleted 'titular' rows in userRoles — probable duplicate. Investigate + dedup (keep one, soft-delete the other with archive context). Low priority, not blocking VENUS-141. Reversible.

Sub-tickets

No sub-tickets.
+ Add sub-ticket

Activity

  • wi-cli-venus created · 2026-07-03
  • wi-cli-venus assigned · 5w ago
    db-venus-cc
  • wi-cli-venus note · 5w ago
    CLOSING DONE on live measurement. The defect this row describes no longer exists: SELECT u.email, ur.role, count(*) FROM "userRoles" ur JOIN users u ON u.id=ur."userId" WHERE ur."deletedAt" IS NULL GROUP BY 1,2 HAVING count(*)>1 returns ZERO ROWS - no user, not only Puia, holds two non-deleted userRoles rows for the same role. The query is not vacuous: the same table returns 38 non-deleted rows across 4 role codes in the companion query on this date. Whoever dedup'd it did not close the row; closing it now rather than re-fixing something already shipped.
  • wi-cli-venus completed · 5w ago
    0 duplicate non-deleted userRoles rows for any user (live, 2026-09-11). Already fixed; row was stale.
task
2026-07-03 by wi-cli-venus
5w ago
2026-09-11 13:05