Yep. it works.

Of course, now I've decided to move that chunk to a separate
'profiles' table.  ;-)
In part because I didn't want people to have to supply all of that
upon registration.

Thanks

On Feb 19, 8:01 am, mdipierro <[email protected]> wrote:
> On a second though. It does not have to be so complex. web2py should
> just find the table. I modifed the code in trunk and now you can just
> do
>
> db.define_table('auth_user',...)
>
> Please check it.
>
> On Feb 19, 7:49 am, mdipierro <[email protected]> wrote:
>
>
>
> > The line
>
> >  auth_table = db.define_table(
>
> > should be
>
> >  auth.settings.table_user = db.define_table(
>
> > so that the following auth.define_tables() knows it is there already.
>
> > On Feb 19, 7:45 am, "G. Clifford Williams"
>
> > <[email protected]> wrote:
> > > In my app I had:
> > >    auth=Auth(globals(),db)                      # authentication/
> > > authorization
> > >    auth.define_tables()                         # creates all needed
> > > tables
> > >    crud=Crud(globals(),db)
>
> > > Which worked wonderfully. Then I got the great idea to add some custom
> > > fields to the auth table(s):
>
> > >    auth=Auth(globals(),db)                      # authentication/
> > > authorization
> > >    #custom AUTH stuff
> > >    auth_table = db.define_table(
> > >        auth.settings.table_user_name,
> > >        Field('picture', ),
> > >        Field('web', ),
> > >        Field('bio', ),
> > >    )
> > >    auth.define_tables()                         # creates all needed
> > > tables
> > >    crud=Crud(globals(),db)
>
> > > This prompted the folowing error:
> > >    table already defined: %s\'  % tablename\nSyntaxError: table
> > > already defined: auth_user\n'
>
> > > Normally I'd just drop the table(s) and blow away the sql files under
> > > 'database/', then restart web2py. One GAE I don't have the luxuary of
> > > such reckless (and effective) behavior. How shall I proceed?
>
> > > Thanks in advance

-- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/web2py?hl=en.

Reply via email to