On Oct 10, 2009, at 1:35 PM, Faheem Mitha wrote:

>
> On Fri, 9 Oct 2009 22:34:11 -0400, Michael Bayer
> <mike...@zzzcomputing.com> wrote:
>
>>
>> On Oct 9, 2009, at 7:35 PM, Faheem Mitha wrote:
>>
>>> Can you explain why removing the "SET search_path TO public;" string
>>> makes a commit happen? You also say "that string you have will not
>>> trip off SQLA's "autocommit" feature." How does this autocommit
>>> feature work, and are there certain strings that will trigger an
>>> autocommit?
>>
>> for textual statements, autocommit is applied when this regexp  
>> matches:
>>
>> AUTOCOMMIT_REGEXP = re.compile(r'\s*(?:UPDATE|INSERT|CREATE|DELETE|
>> DROP|ALTER)',
>>                                re.I | re.UNICODE)
>
> Thanks Michael,
>
> That's very helpful. I didn't realise that sqlalchemy did this kind of
> magic.

we keep it to an absolute minimum but the idea is to avoid issuing  
COMMIT statements when not needed (perhaps there's not much of a  
rationale for that though).


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"sqlalchemy" group.
To post to this group, send email to sqlalchemy@googlegroups.com
To unsubscribe from this group, send email to 
sqlalchemy+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/sqlalchemy?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to