Use params in README
parent
936817b9dc
commit
25ab8bf6a3
|
|
@ -100,7 +100,7 @@ Here is an example:
|
||||||
... ' "NAME" VARCHAR(50) not null,'
|
... ' "NAME" VARCHAR(50) not null,'
|
||||||
... ' primary key ("CUST_ID"))'
|
... ' primary key ("CUST_ID"))'
|
||||||
... )
|
... )
|
||||||
>>> curs.execute("insert into CUSTOMER values (1, 'John')")
|
>>> curs.execute("insert into CUSTOMER values (?, ?)", (1, 'John'))
|
||||||
>>> curs.execute("select * from CUSTOMER")
|
>>> curs.execute("select * from CUSTOMER")
|
||||||
>>> curs.fetchall()
|
>>> curs.fetchall()
|
||||||
[(1, u'John')]
|
[(1, u'John')]
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue