def __call__ self pattern Query self prepare_query pattern print Query

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
def __call__(self,pattern):
#
Query=self.prepare_query(pattern)
print Query
try:
Result=self.do_query(Query)
except:
print "Error is wrong!"
raise
return True