SamDonaldson schrieb: > I wrote my own custom update statement. It's a simple update > statement, When I run the update on mysql, I get the result as > expected, i.e., the table is emtpy, so no rows affected, nothing > done. When I run it in my Tg script, it runs once, and boom, it > stalls on this: > > result = turbogears.database.get_engine().execute(dml) > File "build/bdist.linux-x86_64/egg/sqlalchemy/engine/base.py", line > 776, in execute > File "build/bdist.linux-x86_64/egg/sqlalchemy/engine/base.py", line > 520, in execute > File "build/bdist.linux-x86_64/egg/sqlalchemy/engine/base.py", line > 535, in execute_text > File "build/bdist.linux-x86_64/egg/sqlalchemy/engine/base.py", line > 584, in _execute_raw > File "build/bdist.linux-x86_64/egg/sqlalchemy/engine/base.py", line > 602, in _execute > > And spits out: > > sqlalchemy.exceptions.SQLError: (KeyboardInterrupt) 'UPDATE fr_blah > SET blah1=3, blah2=1 WHERE blah3=1 AND blah4=1 AND blah5=3 AND > blah6=1' () > > Of course, the Keyboard interrupt comes from me when the statement > just hangs. Ok, so what's going on now? I'm almost fed up of > sqlalchemy and definitely thinking of moving to Pylons, but I'm giving > it my last few shots. Am I running out of connections? Am I not > using session.flush() here? This update runs in a loop in one of my > batch jobs in TG. > > Note that I wrote my custom UPDATE and running it through the result > = .... line above. > > thanks, and any help would be appreciated,
Could this be a locking issue? If the app runs, does connecting with the mysql commandline client still work- or does it hang as well? Besides that, you can alwayl ditch SQLAlchemy if you like - but what has that todo with TG vs. Pylons? After all, the model.py is just that - a python module. Go with whatever pleases you. Diez --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---

