SQLREDUCE(1)

🌸 SQLREDUCE(1) β€” User Commands πŸ’…

okay bestie, welcome to sqlreduce, the glow-up your cursed SQL desperately needs. this is a user command, manual section 1, and it's about to become your new obsession.


✨ NAME ✨

sqlreduce β€” Reduce verbose SQL queries to minimal examples πŸ¦‹

like. it takes your messy 400-line query and shrinks it down to the tiniest lil guy that still breaks the same way. main character energy fr.


🌈 DESCRIPTION 🌈

here's the whole vibe, the usage line, exactly as it is:

usage: sqlreduce [-h] [-d DATABASE] [-f FILE] [--sqlstate] [-t TIMEOUT]
       [--debug] [query ...]

and what does she DO? Reduce a SQL query to the minimal query throwing the same error. that's it. that's the whole job. you feed her a big bloated query that errors out, she hands you back the smallest possible query that errors out the same way. no cap. ✨


πŸŽ€ positional arguments

  • query β€” the query to reduce to minimum. yeah, she's just gonna keep shrinking it until there's nothing left to take away. it's giving sculptor. it's giving "not me deleting half your query and it STILL fails bestie" 😭

πŸ’– options

  • -h, --help β€” show this help message and exit. the classic. the icon. press it whenever, she'll never judge you 🫢
  • -d, --database DATABASE β€” database or connection string to use. tell her where to point all this energy, babe πŸ’…
  • -f, --file FILE β€” read query from file. default is stdin, so if you don't say anything she'll just read off the pipe like the loyal bestie she is πŸ“
  • --sqlstate β€” reduce query to same SQL state instead of error message. switch up the matching criteria when you want her chasing the same state instead of the same message. so valid ✨
  • -t, --timeout TIMEOUT β€” statement timeout. default: 500ms. that's her patience threshold and honestly, same. πŸ•
  • --debug β€” no description given in the original, she just EXISTS. mysterious. enigmatic. we don't know what she does and honestly? respect. πŸ’€

🌸 little PSA: that -t default of 500ms is 500 milliseconds, bestie. half a second. blink and it's over. adjust accordingly if your database is a slow lil guy.

πŸ‘‘ SEE ALSO

nothing here! no SEE ALSO section in this one. she stands alone, unbothered, flourishing. πŸ’œ


🧚 sign-off

this has been sqlreduce version 1.5, dated August 2026, from the User Commands manual. go forth and minimize. the vibes are immaculate, the queries are tiny, and you are going to slay. periodt. πŸ’…βœ¨πŸŽ€

πŸ“¦ where this page comes from