I've added this line in my code:
db = DAL('mysql://mydatabase',
folder='applications/gestion/databases',auto_import
=True)
But the result was the same I got at the beginig:
raise errorclass, errorvalue
InterfaceError: (0, '')
El lunes, 7 de mayo de 2012 12:21:17 UTC+2, Samuel Mac escribió:
>
> First of all, I've been searching other google group theads and they help
> me doing all I wanted but now I'm stuck.
> I was looking for getting some hardware information from a computer using
> 3 threads. This threads save the info in the Database. To do that i follow
> the instructions founded in this two forum threads:
> -
> https://groups.google.com/forum/?fromgroups#!searchin/web2py/db$20module/web2py/HbZh7Bbk5RI/sWn0rZaQDRgJ
> - http://osdir.com/ml/web2py/2012-02/msg01692.html
>
> I tryed to pass the DB connection to the class using the __init__ and the
> other way, using the current.db method, but I'm getting the same error:
> raise errorclass, errorvalue
> InterfaceError: (0, '')
>
> Despite my query is very simple: row = db(db.device).select()
>
> Are threads unable to use DB connection?
>
El lunes, 7 de mayo de 2012 12:21:17 UTC+2, Samuel Mac escribió:
>
> First of all, I've been searching other google group theads and they help
> me doing all I wanted but now I'm stuck.
> I was looking for getting some hardware information from a computer using
> 3 threads. This threads save the info in the Database. To do that i follow
> the instructions founded in this two forum threads:
> -
> https://groups.google.com/forum/?fromgroups#!searchin/web2py/db$20module/web2py/HbZh7Bbk5RI/sWn0rZaQDRgJ
> - http://osdir.com/ml/web2py/2012-02/msg01692.html
>
> I tryed to pass the DB connection to the class using the __init__ and the
> other way, using the current.db method, but I'm getting the same error:
> raise errorclass, errorvalue
> InterfaceError: (0, '')
>
> Despite my query is very simple: row = db(db.device).select()
>
> Are threads unable to use DB connection?
>
El lunes, 7 de mayo de 2012 12:21:17 UTC+2, Samuel Mac escribió:
>
> First of all, I've been searching other google group theads and they help
> me doing all I wanted but now I'm stuck.
> I was looking for getting some hardware information from a computer using
> 3 threads. This threads save the info in the Database. To do that i follow
> the instructions founded in this two forum threads:
> -
> https://groups.google.com/forum/?fromgroups#!searchin/web2py/db$20module/web2py/HbZh7Bbk5RI/sWn0rZaQDRgJ
> - http://osdir.com/ml/web2py/2012-02/msg01692.html
>
> I tryed to pass the DB connection to the class using the __init__ and the
> other way, using the current.db method, but I'm getting the same error:
> raise errorclass, errorvalue
> InterfaceError: (0, '')
>
> Despite my query is very simple: row = db(db.device).select()
>
> Are threads unable to use DB connection?
>