-1

i know this question has already been answered but reading:(Sqlite3 / python - Export from sqlite to csv text file does not exceed 20k) I didnt understand it cause i now very little from python and i know very little english so could please someone explain how to do it for a newbie?

Community
  • 1
  • 1
Marcos
  • 13
  • 5
  • The [answer](http://stackoverflow.com/a/17557103/103081) has 5 lines of python code. Please explain: what lines of python code in answer do you not understand? – Paul Aug 12 '15 at 02:32
  • everything, i dont undestand a thing there – Marcos Aug 13 '15 at 15:00
  • Then it would probably be useful to attempt to understand those 5 lines there. We can't read code for you. – msw Aug 13 '15 at 15:41

1 Answers1

1

Well, here is the code i've done so far, its very simple and works well:

with open('output.csv', 'wb') as f:
    writer = csv.writer(f)
    writer.writerow(['Column 1', 'Column 2', ...])
    writer.writerows(data)

Thanks to @Dougal from here

Community
  • 1
  • 1
Marcos
  • 13
  • 5