[Twisted-Python] Help about  adbapi and sqlreflector
    Itamar Shtull-Trauring 
    itamar at itamarst.org
       
    Mon Mar  1 10:35:29 MST 2004
    
    
  
On Mon, 2004-03-01 at 11:57, Celso Providelo wrote:
> pool = adbapi.ConnectionPool('pyPgSQL.PgSQL',database='test')
> pool.runQuery(my_query);
> .... and so on.
1. You don't need row or reflector. Ignore them.
2. runQuery returns a Deferred. So you can do:
def gotResult(x):
    print "db says:", x
pool.runQuery(my_query).addCallback(gotResult)
I suggest reading the Deferred howto and the Enterprise/adbapi howto.
-- 
Itamar Shtull-Trauring    http://itamarst.org
Looking for a job: http://itamarst.org/resume.html
    
    
More information about the Twisted-Python
mailing list