This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author alsadi
Recipients alsadi, pitrou
Date 2009-01-19.11:06:37
SpamBayes Score 2.6409007e-08
Marked as misclassified No
Message-id <1232363198.38.0.929913909213.issue4995@psf.upfronthosting.co.za>
In-reply-to
Content
same thing

[alsadi@pc1 ~]$ python
Python 2.5.2 (r252:60911, Sep 30 2008, 15:41:38) 
[GCC 4.3.2 20080917 (Red Hat 4.3.2-4)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import sqlite3
>>> cn=sqlite3.connect(':memory:')
>>> c=cn.cursor()
>>> c.execute('BEGIN TRANSACTION')
<sqlite3.Cursor object at 0xb7f99da0>
>>> c.execute('create temp table tmp_main (id integer, b text)')
<sqlite3.Cursor object at 0xb7f99da0>
>>> cn.commit()
>>> c.execute('insert into tmp_main (id) values (10);')
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
sqlite3.OperationalError: SQL logic error or missing database
>>> 

to make it easy for you to try it yourself

import sqlite3
cn=sqlite3.connect(':memory:')
c=cn.cursor()
c.execute('BEGIN TRANSACTION')
c.execute('create temp table tmp_main (id integer, b text)')
cn.commit() # this was added on your request
c.execute('insert into tmp_main (id) values (10);')
History
Date User Action Args
2009-01-19 11:06:38alsadisetrecipients: + alsadi, pitrou
2009-01-19 11:06:38alsadisetmessageid: <1232363198.38.0.929913909213.issue4995@psf.upfronthosting.co.za>
2009-01-19 11:06:37alsadilinkissue4995 messages
2009-01-19 11:06:37alsadicreate