This is causing the problem. What if you remove the try... except? What 
ticket do you get?

    try:
        raw_rows = db.executesql('CALL sp_recursive_start(1);', fields=fields)
    except Exception, e:
        print 'ERROR NOW:', e
        db.rollback()




On Saturday, 23 February 2013 12:58:44 UTC-6, __pyslan__ wrote:
>
> After reading this 
> thread<http://en.usenet.digipedia.org/thread/16137/52728/>, 
> as Anthony suggested, I tried this:
>
> import MySQLdb
> from gluon.dal import MySQLAdapter
> MySQLAdapter.driver = MySQLdb
>
> After that, even commenting this block of code I get the result correctly 
> because the print rows, but the error below is thrown anyway:
>
> Traceback (most recent call last):
>   File "/media/sda3/pyslan/PROJECTS/web2py/gluon/main.py", line 632, in 
> wsgibase
>
>     BaseAdapter.close_all_instances('rollback')
>
>   File "/media/sda3/pyslan/PROJECTS/web2py/gluon/dal.py", line 543, in 
> close_all_instances
>
>     db._adapter.close(action)
>
>   File "/media/sda3/pyslan/PROJECTS/web2py/gluon/dal.py", line 523, in close
>
>     getattr(self, action)()
>
>   File "/media/sda3/pyslan/PROJECTS/web2py/gluon/dal.py", line 1670, in 
> rollback
>
>     if self.connection: return self.connection.rollback()
> ProgrammingError: (2014, "Commands out of sync; you can't run this command 
> now")
>
>
>
> The code:
> https://gist.github.com/pyslan/5007364
>
> Something related with this?
> https://groups.google.com/forum/#!msg/web2py/1s7vDix8QC8/mgvot4PEvBgJ
>
>
>
>
>
>

-- 

--- 
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 web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to