summaryrefslogtreecommitdiff
path: root/sandbox/array.py
diff options
context:
space:
mode:
authorFederico Di Gregorio <fog@initd.org>2005-03-23 10:32:30 +0000
committerFederico Di Gregorio <fog@initd.org>2005-03-23 10:32:30 +0000
commit19cb161d2783665093f8cddb7dacd7da0c87703d (patch)
treefbb4835eebf95938081691ee4bfdd960d2ffcf44 /sandbox/array.py
parentcddb1a15d4789ebc08ac4dfc73f1ebffe8fce836 (diff)
downloadpsycopg2-19cb161d2783665093f8cddb7dacd7da0c87703d.tar.gz
Array tokenization seems working.
Diffstat (limited to 'sandbox/array.py')
-rw-r--r--sandbox/array.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/sandbox/array.py b/sandbox/array.py
index b9975a0..af09140 100644
--- a/sandbox/array.py
+++ b/sandbox/array.py
@@ -9,7 +9,9 @@ print curs.fetchone()
curs.execute("SELECT ARRAY['1','2','3'] AS foo")
print curs.fetchone()
-curs.execute("""SELECT ARRAY['','"',''] AS foo""")
+curs.execute("""SELECT ARRAY[',','"','\\\\'] AS foo""")
d = curs.fetchone()
print d, '->', d[0][0], d[0][1], d[0][2]
+curs.execute("SELECT ARRAY[ARRAY[1,2],ARRAY[3,4]] AS foo")
+print curs.fetchone()