I have an SQLite table that contains a BLOB I need to do a size/length check on. How do I do that?
According to documentation length(blob) only works on texts and will stop counting after the first NULL. My tests confirmed this. I’m using SQLite 3.4.2.
I haven’t had this problem, but you could try
length(hex(glob))/2Update (Aug-2012): For SQLite 3.7.6 (released April 12, 2011) and later,
length(blob_column)works as expected with both text and binary data.