SQLite NUL Characters: Why Your Strings Might Be Truncated

Nul Characters in Strings in SQLite

9basilikum💬 0
SQLite NUL Characters: Why Your Strings Might Be Truncated

I explain how SQLite allows NUL characters in strings but truncates them in functions like length() and quote(), leading to confusing results. You might think a string is short, but it actually contains hidden data. I show you how to detect these invisible characters using BLOB casts and remove them to clean your database.

"Small. Fast. Reliable. Choose any three."

More from this day · 2026-07-16