Pr

Provensql – prove two SQL queries are equivalent

Hacker News

Provensql – prove two SQL queries are equivalent

I'm a data/infra engineer and kept hitting the "is this SQL refactor actually safe?" question in review. Provensql decides equivalence of two queries and returns one of four honest verdicts: EQUIVALENT (proven), DIFFERENT (with a concrete counterexample row), SCHEMA_CHANGE, or UNKNOWN — it refuses rather than guess. It's sound by construction: it never returns a false EQUIVALENT. Across 511 equivalence-breaking mutations it produced zero. There's an SMT proof engine for the conjunctive fragment and a counterexample search for the rest. As a baseline I ran a gpt-5 judge over the same 213 labeled pairs — it claimed EQUIVALENT on 2 pairs that actually differ; provensql structurally can't make that error. The part I'm most interested in feedback on: it also catches rewrites valid over the reals but that diverge under IEEE-754 (reassociation) or change runtime-error behavior (a/b → SAFE_DIVIDE) — cases every other checker treats as exact-real and silently accepts. Try it: pip install provensql, a GitHub Action that gates PRs (github.com/nac7/provensql-action), and an interactive demo in the repo. Apache-2.0, github.com/nac7/provensql. Feedback on fragment coverage and which dialects to add next is very welcome.

Share card

Actual performance

1points
Did not reach leaderboard

Launch Intel predictions

Analyze your own launch →
Indie HackersFits the IH revenue-focused audience · Missing: supports, reddit linkedin, podcasting
52%52% predicted probability of success on Indie Hackers, based on ML models trained on real launch data.
best fitHighest predicted score across all platforms for this description.
Product HuntUnlikely to reach the leaderboard · Missing: mac, agents, macos
49%49% predicted probability of success on Product Hunt, based on ML models trained on real launch data.
Hacker NewsMay not resonate with HN audience · Strong signals: ide, io · Missing: https docs, excited, just released
44%44% predicted probability of success on Hacker News, based on ML models trained on real launch data.
nativeThis product was originally launched on this platform.
AppSumoMay struggle as an AppSumo deal · Missing: plus, platform, intuitive
29%29% predicted probability of success on AppSumo, based on ML models trained on real launch data.
TrustMRRLess likely to generate early MRR · Missing: mobile apps, ios, personal
29%29% predicted probability of success on TrustMRR, based on ML models trained on real launch data.
Acquire.comPre-revenue stage for this audience · Strong signals: active · Missing: arr, mrr, revenue
20%20% predicted probability of success on Acquire.com, based on ML models trained on real launch data.
BetaListMay not resonate with beta-testers · Missing: web3, chat, crypto
4%4% predicted probability of success on BetaList, based on ML models trained on real launch data.

Correct prediction on native model

Similar products

Di
DigData – convert SQL to MongoDB queries66%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

DigData – convert SQL to MongoDB queries

Hacker News6
sq
sqltop – Find the most resource consuming SQL Server queries55%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

sqltop – Find the most resource consuming SQL Server queries

Hacker News18
Vi
Visualize SQL Queries56%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

Visualize SQL Queries

Hacker News259
AI2sql
AI2sql21%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

Write SQL queries with no knowledge of SQL

AppSumo4
Cs
Csql – Python lib for composeable SQL queries57%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

Csql – Python lib for composeable SQL queries

Hacker News89
De
DeployQL- collaborative, trackable SQL queries71%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

DeployQL- collaborative, trackable SQL queries

Hacker News5
We
Webapp to Format SQL Queries for Readability64%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

Webapp to Format SQL Queries for Readability

Hacker News4
FS
FSQL – Search through your file system with SQL-esque queries62%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

FSQL – Search through your file system with SQL-esque queries

Hacker News341
Op
Optimize SQL Queries for Free72%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

Optimize SQL Queries for Free

Hacker News1
Cr
Create a KPI Dashboard by Pasting SQL Queries69%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

Create a KPI Dashboard by Pasting SQL Queries

Hacker News8