Repository navigation
quack: pin SQL NULL operands over existing sql_where (tests + PostgreSQL differential) - #1682
Conversation
…y plane Corrects the polyfill map's G1 rows and gap item 1, which said a NULL literal needs a constant-UNKNOWN Filter leaf. It does not: sql_where's leaf arm already gives a NULL operand T = F = empty. sql_where's doc comment no longer lists the NULL literal as out of scope. Doc and board only; no code change. Tests follow in this branch. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013z2e1YXkm6o6HNrDn5BPWA
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013z2e1YXkm6o6HNrDn5BPWA
…SQL differential) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013z2e1YXkm6o6HNrDn5BPWA
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013z2e1YXkm6o6HNrDn5BPWA
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars. ⚙️ Run configuration
Warning Billing warning: we have not been able to collect payment for this subscription for more than 72 hours. Please update the payment method or pay any pending invoices in Billing to avoid service interruption. Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Add Carrot credits or activate Agent usage billing to use Autofix |
…1680/#1682, boundaries Only this session's rows and entry: the STATUS_BOARD "D-QSP-0 remainder" row (In PR -> Shipped, slice 2 added), PR_ARC entries for #1675, #1680 and #1682 prepended, and the entry now states that Quack has no NULL-literal Filter variant, that the PostgreSQL examples are lab evidence and not CI, and #1682's final CI (18/18 green on 96e8010). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013z2e1YXkm6o6HNrDn5BPWA
D-QSP-0 slice 2 (G1). Follow-up to #1680. Three files: two new ones and my own board entry.
Contract
SQL NULL is absence of validity, never
0and never FALSE. A nullable value is a value lane plus a validity plane (1 = present, 0 = NULL).For a nullable predicate:
T = valid ∧ pF = valid ∧ ¬p¬(T ∨ F)Quack's
Tisf.sql_where(nullable). ItsFisFilter::Not(f).sql_where(nullable).NULL operand.
x = NULL,NULL < c,NULL::booleanand the NULL member ofINall map toFilter::Cmp(N, …).Nis a column whose value lane is an alias of an existing lane and whose validity plane is all clear, listed innullable. ItsTandFare empty on every row.FALSE literal. A
Filter::Planeover an all-zero plane that is present, so itsFis every row. FALSE and UNKNOWN stay distinct.Reused, nothing added
Filter::{Cmp, Plane, And, Or, Not},sql_where,lower,lower_fusedexecute_intowithOut::MaskXorthenAnyfor every comparisonThere is no new
Filtervariant, evaluator, counting loop or terminal, andsrc/lib.rsis untouched.Files
crates/lance-graph-quack/tests/sql_null_operand.rs(new, 11 tests, runs in CI)crates/lance-graph-quack/examples/qsp_null_operand_pg_parity.rs(new, PostgreSQL differential, prints SKIP without a server).claude/board/entries/2026-10-21-d-qsp-0-scalar-aggregates-null.md(my entry, slice 2 section)Evidence
Committed tests (8 rows, the NULL payload equals the IN value). Both lowerings are checked and must agree. Results:
x = NULLT = F = ∅NOT (x = NULL)T = F = ∅x IN (1, NULL)T= the matches,F = ∅x NOT IN (1, NULL)T = ∅FplanePostgreSQL 16.15, 2000 random expressions × 200 rows. The
TandFplanes equal PostgreSQL on every expression, in both lowerings, and again with every invalid payload re-drawn. The run covered:NOT IN (…, NULL)with an emptyT.Built-in disable arms (each asserted > 0):
nullablediffers on 1107.Disable runs:
nullable: 9/11 red.sql_whereskipped: 9/11 red.sql_where's leaf arm without its validity gate): 9/11 red. The PostgreSQL example exits 101.Gates: the quack crate has 137 tests passing, clippy
-D warningsis clean, and fmt is clean.Not in this PR
entries/2026-10-21-pg-classview-polyfill-map.mdare still stale. That file belongs to another session; the entry names the rows.COALESCE,NULLIFand nullable arithmetic; the NULL branch of aNOT INsubquery.Merge is attended: I will not merge this PR.
Generated by Claude Code