Hi all,
How would you go about adding items from a cursor to a dictionary?

i tried this but to no avail:

>>> cur.execute('select * from schedule limit 10')
<sqlite3.Cursor object at 0x0112CE60>
>>> for i in range(len(cur.fetchall())):
d[i]=cur.fetchall()[i]

Traceback (most recent call last):
  File "<pyshell#70>", line 2, in <module>
    d[i]=cur.fetchall()[i]
IndexError: list index out of range

Thanks
_______________________________________________
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor

Reply via email to