It is

    form = SQLFORM(db.hellotest)

not

    form = SQLFORM('db.hellotest') # error

On Mar 26, 9:14 pm, Michael <michael.no...@gmail.com> wrote:
> Hey guys, here is my default.py
>
> def index():
>     rows = db().select(db.hellotest.ALL)
>     return dict(rows=rows)
>
> def newname():
>     form = SQLFORM('db.hellotest')              <- THIS LINE HAS AN
> ERror
>     if form.accepts(request.vars, session):
>         session.flash('added')
>         redirect(URL(r=request, f='index'))
>
>     return dict(form=form)
>
> And the appended line from the framework also has an error.
>
> response._vars=response._caller(newname)
>
> Here is my db.py file:
>
> db=SQLDB('sqlite://db.db')
> db.define_table('hellotest', SQLField("test", "string"))
>
> I can't seem to figure out why it's throwing these errors? My code
> seems to check out fine.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"web2py Web Framework" group.
To post to this group, send email to web2py@googlegroups.com
To unsubscribe from this group, send email to 
web2py+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/web2py?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to