well, in sql-ese truncate is not the same as delete. 
Putting in simple words, any backend doesn't enable you to truncate a table 
if that "truncation" leads to other table records's being deleted (and 
that's your case with a FK).
The main difference between truncate and delete (the faster execution of 
truncate is highlighted by this corner-case) is that by default truncation 
drops whatever is in the table without taking care of possible 
side-effects. delete instead goes row by row eventually considering side 
effects.
This leads the backend to mark in advance any table with a FK as 
non-truncable, because it has BY DEFAULT a side-effect: pruning all 
referenced records.
>
>
>>>>

-- 
Resources:
- http://web2py.com
- 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 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to