There's always the naive option.

query = ('species', 'lifestyle', 'coolness', 'tentacles=>8')
db.execute('SELECT %s, %s, %s % FROM creatures WHERE %s;' % query)
record = dict(zip((query), (db.fetchall()))
array = '''{
             '''
for k,v in record:
  array.append('"(k)":"(v)"')
array.append('''
                }''')




--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to