What is the most elegant method for dumping a list in python into an sqlite3 DB as binary data (i.e., a BLOB cell)?
data = [ 0, 1, 2, 3, 4, 5 ]
# now write t
See this general solution at SourceForge which covers any arbitrary Python object (including list, tuple, dictionary, etc):
y_serial.py module :: warehouse Python objects with SQLite
"Serialization + persistance :: in a few lines of code, compress and annotate Python objects into SQLite; then later retrieve them chronologically by keywords without any SQL. Most useful "standard" module for a database to store schema-less data."
http://yserial.sourceforge.net