Skip to content

Make fn_read_fish_edit_list an inline TVF (fish page habitat timeout) - #93

Merged
BalinTomsk merged 1 commit into
mainfrom
fish-edit-list-inline
Nov 15, 2026
Merged

BalinTomsk merged 1 commit into
mainfrom
fish-edit-list-inline

Conversation

@BalinTomsk

Copy link
Copy Markdown
Owner

dbo.fn_read_fish_edit_list() built the habitat row for every fish (1,063) into a table variable with 10 UPDATEs before wfFishViewer.LoadHabitat's WHERE fish_id = applied. The fish page hit the 30 s command timeout 24 times on prod since 2026-10-27 (plus 4 in LoadUnEditedFish, same function).

  • Rewritten as an inline TVF: same columns, same order; one fish 1,841 ms → 2 ms locally.
  • New unit_test@FishEditList.sql (3 tests): TEST 1 failed on the old function, all pass now; unit_test@FishEditor.sql still passes.
  • Already LIVE on prod and local envionx (all 1,063 rows identical before/after); CTRL queued in ctrlLogBag.

Full suite: no FAIL lines; unrelated pre-existing errors in unit_test@CatchMemo.sql TEST 43 and the untracked unit_test@FishReasoningJson.sql.

🤖 Generated with Claude Code

The multi-statement version built all 1,063 fish into a table variable with
10 UPDATEs before wfFishViewer.LoadHabitat's WHERE fish_id applied; the fish
page hit the 30 s command timeout 24 times on prod since 2026-10-27. Same
columns in the same order; one fish 1,841 ms -> 2 ms locally.

Tests: unit_test@FishEditList.sql (3; TEST 1 failed on the old function).
LIVE on prod 2026-11-15 (1,063 rows identical before/after).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@BalinTomsk
BalinTomsk merged commit 0051b22 into main Nov 15, 2026
@BalinTomsk
BalinTomsk deleted the fish-edit-list-inline branch November 15, 2026 14:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant