#NEWLINE# def add_columns( header , c , clear = False ) : #NEWLINE# #INDENT# '\n    add any missing columns to the samples table\n    ' #NEWLINE# for column in header : #NEWLINE# #INDENT# try : #NEWLINE# #INDENT# c . execute ( 'ALTER TABLE samples ADD COLUMN {0}' . format ( column ) ) #NEWLINE# #UNINDENT# except : #NEWLINE# #INDENT# pass #NEWLINE# #UNINDENT# if clear : #NEWLINE# #INDENT# c . execute ( 'UPDATE samples set {0} = NULL;' . format ( column ) )