Hi First of all i must say i'm pretty much impressed of how easy it is to buid a sqlite db up within minutes/hours of work. I'm... amazed :)
Still, i'm lacking answears. My (soon-to-be-open-source-when-there-will-be-interesting-source-to-open) project is the following: i scan for files recursively (jpeg files) and parse it's header. Every piece of the header means something, represented by an absolute path (such as "/sof/content/nr_components" ). I'd like to automatically fill a local db with these parameters, with: - the column name = the absolute path - a line = a file Some files have optional fields, so what i'd like to do is, whenever such a file is scanned and parsed, i want my software to - check first if the column already exists; that, i have no idea how to achieve it - if not, create the table : cur.execute("alter table jpgs add column %s" % (field.path) ) - then add the parameter value to the (new or not) column; but i don't want a new line to be created every time; is an "update" query the good one? I read something about vaccuming the table? What about it? Should i rather parse the entire file and commit the summary to the table? How to add columns? Thanks a lot for your help Regards Florent