File: example.py

package info (click to toggle)
python-agate-sql 0.5.5-4
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, sid
  • size: 236 kB
  • sloc: python: 461; makefile: 123
file content (13 lines) | stat: -rwxr-xr-x 278 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
#!/usr/bin/env python

import agate
import agatesql

table = agate.Table.from_sql('sqlite:///example.db', 'test')

print(table.column_names)
print(table.column_types)
print(len(table.columns))
print(len(table.rows))

table.to_sql('sqlite:///example.db', 'test', overwrite=True)