On 27 jun, 09:42, mdipierro <mdipie...@cs.depaul.edu> wrote:
> Those errors are fine. request.vars.id is a Reference field to the
> newly created record. It can be converted to int and treated as a int
> but it is not a int. response.flash should be a string or a helper. If
> you pass a Reference without converting to int, it will cause the
> problems below.
>
> The trigger must be creating some problem. It may be it interferes
> with the machanism used by web2py to get the id of the last inserted
> record.
>

Perhaps the trigger is really affecting the way you get the ID.

Please see this [1] and [2]. Web2py use "SELECT @@IDENTITY;" to get
the id.


In my case, the trigger does not do an insert into another table, but
it makes an update in another table. Then the problem that is
mentioned in the links that showed not apply.

Jose

[1] http://msdn.microsoft.com/en-us/library/ms190315.aspx
[2] 
http://cgaskell.wordpress.com/2006/11/15/using-identity-vs-scope_identity-and-further-implications-with-triggers/

Reply via email to