Thanks, I delete database folder, delete and recreate database on mysql and
web2py recreate all tables.
Now all is ok!
Il giorno lunedì 10 ottobre 2016 16:36:22 UTC+2, Marlysson Silva ha scritto:
> If your data are tests ,you could delete databases folder or the
> migrations file , and restart server to forget some references to user
> Em segunda-feira, 10 de outubro de 2016 11:13:22 UTC-3, Fabio Ceccarani
>> I have this problem: a table have a field that is a reference to id of
>> BEFORE it was:
>> NOW is:
>> Now the table 'users' is n more used.
>> The problem is that if I insert new courses record the app faults with
>> this error:
>> <class 'gluon.contrib.pymysql.err.IntegrityError'> (1452, u'Cannot add or
>> update a child row: a foreign key constraint fails (`course`.`courses`,
>> CONSTRAINT `courses_ibfk_1` FOREIGN KEY (`id_user`) REFERENCES `users`
>> (`id`) ON DELETE CASCADE)')
>> In query is present 'users' table that is no more used nowhere (I
>> searched it in all project file!). If the user is present in users table
>> the record in courses is created.
>> Auth_user have extra field:
>> auth.settings.extra_fields['auth_user']= [
>> I read all post about migrate, fake_migrate, etc, but for me there is a
>> problem with migration. For example if I delete a table that is declared in
>> db.py, it is NOT recreated (i tried all combination in the world of
>> migrate, fake_migrate, etc!!!).
>> It could be a mysql permission/users/other problem?
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
You received this message because you are subscribed to the Google Groups
To unsubscribe from this group and stop receiving emails from it, send an email
For more options, visit https://groups.google.com/d/optout.