Jim

Thank you.  I got it to work now.
I'm curious why controllers don't need an explicit commit() like
your script does.  Perhaps TurboGears automatically does a silent
commit()
after every controller call?

Also, I assume your TurboGears apps have a line in your model file
like the following..

__connection__ = turbogears.database.PackageHub("myproject")

Why didn't you use this __connection__ reference in your example?
Perhaps, using a model object's _connection attribute is "safer"
because you are only exposing
a database connection for one class?

Also,

On May 2, 7:55 am, Jim Steil <[EMAIL PROTECTED]> wrote:
> [EMAIL PROTECTED] wrote:
>
> > On May 1, 1:46 am, lilspikey <[EMAIL PROTECTED]> wrote:
>
> >> Inside a controller your code will be running in a transaction -
> >> whereas elsewhere it won't.  There's a bit of stuff here:
>
> >>http://docs.turbogears.org/1.0/ModelOutsideTG
>
> > I printed that and read it.  Can you please elaborate how you modify
> > database
> > outside of a controller?  I'm still having problems.
>
> > cs
>
> I made a quick nonsensical example.  I think this is what you're looking
> for...
>
> http://paste.turbogears.org/paste/2637
>
>     -Jim
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TurboGears" 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/turbogears?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to