web2py db manual table entries

12 views
Skip to first unread message

Ali Kayes

unread,
Aug 6, 2014, 9:57:38 PM8/6/14
to web...@googlegroups.com

So, in my db.py, I defined a table as such:

db.define_table('dummy',
            Field('name'),
            Field('category'),
            Field('number'))

But how would I add my own values in that table? It seems like if I do something like:

db.dummy.insert(name='jon',category='cat',number='2')

I get a "Database is locked" error. So, how can I have my own manual table? I am using SQLite.

Massimo Di Pierro

unread,
Aug 8, 2014, 10:02:47 PM8/8/14
to web...@googlegroups.com
Do you have a shell open with a transaction uncommitted? Or perhaps another instance of web2py that is stuck in a commit? Try kill all your pyhton instances.
Reply all
Reply to author
Forward
0 new messages